Re: Pasting into another app
Re: Pasting into another app
- Subject: Re: Pasting into another app
- From: Dave DeLong <email@hidden>
- Date: Fri, 09 Jan 2009 14:38:25 -0700
With the CGEvents, you don't have to post four. You can post two:
One for V down and one for V up. You can use the modifierFlags on the
CGEvent to specify that Command should be down on V down.
Dave
On Jan 9, 2009, at 2:34 PM, Michael Vannorsdel wrote:
Checkout CGEventCreateKeyboardEvent and CGEventPost to synthesize
keyboard events. You have to make and post an event for the key
down and then the key up. So: command key down, V key down, V key
up, command key up. There's also CGPostKeyboardEvent which is
easier to use but not recommended for all cases.
_______________________________________________
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