Fixed issue with special keys being remapped again (resulting in mangeled key codes in release)

This commit is contained in:
michael starke
2014-12-03 17:30:13 +01:00
parent 7ce789790c
commit 559f7cd78f
3 changed files with 7 additions and 6 deletions

View File

@@ -323,11 +323,10 @@
Set the modifiers to the ones we want
We use our private event source so no modifier reset should be needed
*/
CGEventSetFlags(pressKey,flags);
CGEventSetFlags(pressKey, flags);
CGEventSetFlags(releaseKey, flags);
/* Send the event */
NSLog(@"Seding %@", self);
CGEventPost(kCGHIDEventTap, pressKey);
usleep(0.05 * NSEC_PER_MSEC);
CGEventPost(kCGHIDEventTap, releaseKey);