Connects or disconnects the mouse and cursor while an application is in the foreground.
- macOS 10.0+
- Mac Catalyst 13.0+
- Core Graphics
trueif the mouse and cursor should be connected; otherwise, pass
A result code. See Core Graphics Data Types and Constants.
When you call this function to disconnect the cursor and mouse, all events received by your application have a constant absolute location but contain mouse delta (change in X and Y) data. You may hide the cursor or change it into something appropriate for your application. You can reposition the cursor by using the function
CGDisplay or the function