Mouse tracking for macOS. Receive the screen position of various mouse events.
npm install osx-mouse-cocoa
This is a fork of osx-mouse that works on macOS Mojave without accessibility permissions. Unlike
osx-mouse, the events are only emitted when the application is in focused. Even when the application is unfocused,
move events are still generated when hovering over the application windows.
The module returns an event emitter instance.
var mouse = ;mouse;
To stop tracking events, call
mouse.unref() methods have been retained for API compatibility with
osx-mouse, but they have no effect.
The events emitted are:
right-drag. For each event the screen coordinates are passed to the handler function.