Re: Alternative startup for application
Re: Alternative startup for application
- Subject: Re: Alternative startup for application
- From: Michael Nickerson <email@hidden>
- Date: Fri, 02 Apr 2010 23:13:57 -0400
On Apr 02, 2010, at 10:12 PM, Gideon King wrote:
> That's the instance method. New in 10.6 is the class method of the same name, which is what I need in this case, since I don't have an event to work with.
>
> On 03/04/2010, at 12:09 PM, Klaus Backert wrote:
>
>>
>> On 3 Apr 2010, at 01:15, Gideon King wrote:
>>
>>> Excellent, I like the new way of doing it using NSEvent directly, but I do need to support Leopard.
>>
>> - (NSUInteger)modifierFlags
>>
>> Available in Mac OS X v10.0 and later.
>>
>
You can use CGEventSourceKeyState( kCGEventSourceStateCombinedSessionState, 0x3A ). That function will get the key down state at the time of the call, and 0x3A is the key code for the option key.
--------------------------------------
Darkshadow
(aka Michael Nickerson)
http://www.nightproductions.net
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden