Xojo Conferences
XDCMay2019MiamiUSA

[MBS] Getting the front document of other applications? (MBS Xojo Plugin Mailinglist archive)

Back to the thread list
Previous thread: [MBS] 6.2pr3
Next thread: [MBS] PDFLibLiteMBS on Intel Macs


Re: [MBS] MIDI Destinations and External Devices   -   Ron Benditt
  [MBS] Getting the front document of other applications?   -   Dennis Birch
   Re: [MBS] Getting the front document of other applications?   -   Christian Schmitz
    Re: [MBS] Getting the front document of other applications?   -   Dennis Birch
     Re: [MBS] Getting the front document of other applications?   -   Christian Schmitz
     Re: [MBS] Getting the front document of other applications?   -   Knut Lorenzen
      Re: [MBS] Getting the front document of other applications?   -   Dennis Birch

[MBS] Getting the front document of other applications?
Date: 20.05.06 06:04 (Fri, 19 May 2006 22:04:40 -0700)
From: Dennis Birch
Is there anything built into the MBS plugins to get the name of the
front document window of the frontmost application (assuming it is
not my own)? I looked at the CarbonApplicationEventsMBS class and the
ProcessMBS class, but neither seems to have anything to do the job.
Am I missing something?
_______________________________________________
Mbsplugins_monkeybreadsoftware.info mailing list
<email address removed>
http://ml01.ispgateway.de/mailman/listinfo/mbsplugins_monkeybreadsoftware.info

Re: [MBS] Getting the front document of other applications?
Date: 20.05.06 12:22 (Sat, 20 May 2006 13:22:31 +0200)
From: Christian Schmitz
Dennis Birch <<email address removed>> wrote:

> Is there anything built into the MBS plugins to get the name of the
> front document window of the frontmost application (assuming it is
> not my own)? I looked at the CarbonApplicationEventsMBS class and the
> ProcessMBS class, but neither seems to have anything to do the job.
> Am I missing something?

The "Accessibility services" folder has an example project "Frontmost
Window.rb". Try it.

Gruß
Christian

-

Re: [MBS] Getting the front document of other applications?
Date: 20.05.06 18:26 (Sat, 20 May 2006 10:26:46 -0700)
From: Dennis Birch
At 1:22 PM +0200 5/20/06, Christian Schmitz wrote:
>Dennis Birch <<email address removed>> wrote:
>
>> Is there anything built into the MBS plugins to get the name of the
>> front document window of the frontmost application (assuming it is
>> not my own)? I looked at the CarbonApplicationEventsMBS class and the
>> ProcessMBS class, but neither seems to have anything to do the job.
>> Am I missing something?
>
>The "Accessibility services" folder has an example project "Frontmost
>Window.rb". Try it.

Thanks, Christian. It looks like that will provide me with everything
I need. The only drawback I see is that it requires that the Mac's
Accessibility settings be enabled. Do you know if there is any way to
do that for the end-user programmatically? That would be an extra
nice touch.
_______________________________________________
Mbsplugins_monkeybreadsoftware.info mailing list
<email address removed>
http://ml01.ispgateway.de/mailman/listinfo/mbsplugins_monkeybreadsoftware.info

Re: [MBS] Getting the front document of other applications?
Date: 20.05.06 18:53 (Sat, 20 May 2006 19:53:02 +0200)
From: Christian Schmitz
Dennis Birch <<email address removed>> wrote:

> Do you know if there is any way to do that for the end-user
> programmatically?

No. It requires an admin password.

Gruß
Christian

-

Re: [MBS] Getting the front document of other applications?
Date: 20.05.06 18:59 (Sat, 20 May 2006 19:59:36 +0200)
From: Knut Lorenzen
Dennis Birch schrieb dereinst (am 20.05.2006 19:26 Uhr) via
<email address removed>:

> Accessibility settings be enabled. Do you know if there is any way to
> do that for the end-user programmatically?

Here's an AppleScript snippet that does what you want:

tell application "System Events"
if UI elements enabled = false then
set UI elements enabled to true
end if
end tell

But, as Christian already said, it requires admin authorization - for good
reasons, if you ask me :)

Cheers,

Knut

_______________________________________________
Mbsplugins_monkeybreadsoftware.info mailing list
<email address removed>
http://ml01.ispgateway.de/mailman/listinfo/mbsplugins_monkeybreadsoftware.info

Re: [MBS] Getting the front document of other applications?
Date: 20.05.06 19:15 (Sat, 20 May 2006 11:15:55 -0700)
From: Dennis Birch
At 7:59 PM +0200 5/20/06, Knut Lorenzen wrote:
>Dennis Birch schrieb dereinst (am 20.05.2006 19:26 Uhr) via
><email address removed>:
>
>> Accessibility settings be enabled. Do you know if there is any way to
>> do that for the end-user programmatically?
>
>Here's an AppleScript snippet that does what you want:
>
>tell application "System Events"
> if UI elements enabled = false then
> set UI elements enabled to true
> end if
>end tell
>
>But, as Christian already said, it requires admin authorization - for good
>reasons, if you ask me :)

That works for me! Thanks much.
_______________________________________________
Mbsplugins_monkeybreadsoftware.info mailing list
<email address removed>
http://ml01.ispgateway.de/mailman/listinfo/mbsplugins_monkeybreadsoftware.info