mirror of
https://github.com/glfw/glfw.git
synced 2025-06-15 12:12:16 +00:00
OSX fixed set cursor position on retina in fullscr.
Weird behavior. glfwSetCursorPos worked fine in fullscreen if I had monitor connected to the laptop, on either display. But was offset by about 200px in fullscreen if no monitor was connected.
This commit is contained in:
parent
28a0dc0fb9
commit
6a26ef0920
@ -1058,6 +1058,10 @@ void _glfwPlatformSetCursorPos(_GLFWwindow* window, double x, double y)
|
||||
CGDisplayMoveCursorToPoint(window->monitor->ns.displayID,
|
||||
CGPointMake(x, y));
|
||||
}
|
||||
else if ([window->ns.view isInFullScreenMode])
|
||||
{
|
||||
CGWarpMouseCursorPosition(CGPointMake(x, y));
|
||||
}
|
||||
else
|
||||
{
|
||||
const NSRect contentRect = [window->ns.view frame];
|
||||
|
Loading…
Reference in New Issue
Block a user