Stealing keyboard focus without activating
Stealing keyboard focus without activating
- Subject: Stealing keyboard focus without activating
- From: Ingvar Nedrebo <email@hidden>
- Date: Sat, 8 Jul 2006 15:39:13 +0100
I need to get keyboard focus without my app becoming active.
Here's why: I've got this third-party media app that shows content in
fullscreen. My app is meant to be an alternate front-end to that app,
offering (in my view) better controls for play/pause/ff, that kind of
thing.
So my app puts up a control panel in front of the media apps content
window (using a hotkey). When my panel is up, I want it to have
keyboard focus. I tried doing this by forcing my app active, using
this technique from Daniel Jalkut:
<http://www.cocoabuilder.com/archive/message/cocoa/2005/11/5/149489>
However, forcing my app active causes the media up to come out of
fullscreen mode. That makes some sense, I guess, but doesn't help me.
I've made my app a background app (LSUIElement) with a menu in a
status item (NSStatusItem).
Quicksilver does exactly what I want. When the media app is in
fullscreen, I bring up Quicksilver's panel, type away and dismiss it
without disturbing the media app at all. Does anybody know how
Quicksilver (and similar apps) does this?
Regards,
i.
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden