Keep mouse cursor state sane on focus change in Quartz driver.

Fixes Bugzilla #12.

--HG--
extra : convert_revision : svn%3Ac70aab31-4412-0410-b14c-859654838e24/trunk%401564
This commit is contained in:
Ryan C. Gordon 2006-03-21 00:35:22 +00:00
parent 625655e271
commit 8e0454b5e9

View file

@ -627,6 +627,12 @@ static void QZ_DoActivate (_THIS)
QZ_PrivateWarpCursor (this, cursor_loc.x, cursor_loc.y);
QZ_ChangeGrabState (this, QZ_ENABLE_GRAB);
}
else {
/* Update SDL's mouse location */
NSPoint p;
QZ_GetMouseLocation (this, &p);
SDL_PrivateMouseMotion (0, 0, p.x, p.y);
}
}
static void QZ_DoDeactivate (_THIS) {