NSEventMaskCursorUpdate with addGlobalMonitorForEventsMatchingMask not triggering

Viewed 50

I am having trouble getting cursor updates with addGlobalMonitorForEventsMatchingMask and NSEventMaskCursorUpdate.

I was hoping this handler would be called when the (global) mouse cursor changes, but the handler is never called when the mouse cursor changes.

Does anyone have more information on when this can be used? Perhaps I am misunderstanding when this event is emitted.

Thanks

[NSEvent addGlobalMonitorForEventsMatchingMask:NSEventMaskCursorUpdate handler:^(NSEvent *mouseEvent) {
   ....
}];
0 Answers
Related