Re: Menu Items and the kAXPickAction Action
Re: Menu Items and the kAXPickAction Action
- Subject: Re: Menu Items and the kAXPickAction Action
- From: Michael Kamprath <email@hidden>
- Date: Sat, 31 Aug 2002 12:35:06 -0700
on 8/30/02 8:46 AM, Eric Schlegel at email@hidden wrote:
>
On Thursday, August 29, 2002, at 10:48 PM, Michael Kamprath wrote:
>
>
> When ever I use the Accessibility API to send a menu item that
>
> kAXPickAction
>
> action message, if the menu item belongs to an Application that is not
>
> the
>
> current front application, the action does not occur until that
>
> application
>
> is brought to the front.
>
>
>
> Is this the intended behavior of the Accessibility API? Is there any
>
> way to
>
> make the kAXPickAction action occur while the application remains in
>
> its
>
> current non-front layer?
>
>
Interesting point. We hadn't considered that aspect of the action.
>
>
It's not "intended behavior", but it doesn't surprise me either. In
>
order to implement the pick action, we have to fool the app into
>
thinking a mouse-down landed on the menubar. Background apps have
>
hidden menubars, so the app probably doesn't get an inMenuBar response
>
from FindWindow when it checks the mouse position.
>
It in a way makes sense to me that the kAXPickAction only works when an
application is in front, as OS handling of the menu events aside, most
applications disable menu items when it's windows receive a disable event.
Even though the application's front window would imply to the user that some
menu items are enabled, the application not being in front implies that its
front window is inactive and in turn the application's implementer might
have the menu items disabled.
Does this boil down to an UI design issue then? Should menu items be
available for picking if the application is not the front application?
>
Please file a feature request and I'll see if I can make this work
>
somehow.
>
Right now my code is bringing the target application to front, executing the
kAXPickAction, then putting the original front application back in front. I
find this adequate for now. I think, however, that though I'd sure menu item
selection in background applications can be implemented, the questions I
pose above probably need to be answered first.
Personally, I am a fence-sitter on the the answers to the UI design issue of
this. I just realize that either answer has its own set of causal
implications.
>
-eric
Michael F. Kamprath
email@hidden
Keyboard Maestro - Conduct Your Mac Like a Pro!
Download a free copy today at: www.KeyboardMaestro.com
_______________________________________________
accessibility-dev mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/accessibility-dev
Do not post admin requests to the list. They will be ignored.