mirror of
https://github.com/minetest/irrlicht.git
synced 2024-11-20 01:00:24 +01:00
Use CGWarpMouseCursorPosition
This commit is contained in:
parent
426730bf91
commit
392df9bae3
@ -1172,9 +1172,8 @@ void CIrrDeviceMacOSX::setMouseLocation(int x,int y)
|
||||
c.x = p.x;
|
||||
c.y = p.y;
|
||||
|
||||
CGEventRef ev = CGEventCreateMouseEvent(NULL, kCGEventMouseMoved, c, kCGMouseButtonLeft);
|
||||
CGEventPost(kCGHIDEventTap, ev);
|
||||
CFRelease(ev);
|
||||
CGWarpMouseCursorPosition(c);
|
||||
CGAssociateMouseAndMouseCursorPosition(YES);
|
||||
}
|
||||
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user