Skip to content

Instantly share code, notes, and snippets.

@linuxsable
Created November 21, 2013 08:12
Show Gist options
  • Save linuxsable/7577746 to your computer and use it in GitHub Desktop.
Save linuxsable/7577746 to your computer and use it in GitHub Desktop.
- (void)applicationDidFinishLaunching:(NSNotification *)notification {
id bacon = [NSEvent addGlobalMonitorForEventsMatchingMask:NSKeyDownMask handler: ^(NSEvent *event) {
NSUInteger flags = [event modifierFlags] & NSDeviceIndependentModifierFlagsMask;
NSLog(@"hi");
if (flags == NSControlKeyMask + NSShiftKeyMask) {
}
}];
NSLog(@"%@", bacon);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment