You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This bug report was migrated from our old Bugzilla tracker.
Reported in version: 1.2.14 Reported for operating system, platform: Windows 7, All
Comments on the original bug report:
On 2010-02-20 12:46:13 +0000, wrote:
This occurs when the openmsx emulator is running full screen and the user reverts to the desktop by hitting Win+D.
In this case, the screen size reverts to the original size (in my case, 1920x1200) instead of 1024x768. However, in this scenario, the SDL window is now off-screen, and Windows returns some rather odd values for the physical position of the middle of the window (e.g. center.x = -31520, center.y = -31640).
Long story short, we created an SDL patch for openmsx builds that causes DIB_GenerateMouseMotionEvent to only post a new event if (after calling SetCursorPos) the cursor's position actually changed from the original position (in the scenario I describe, it actually doesn't: it was 0,0 before and it remains 0,0 after calling SetCursorPos).
In other words:
diff -ru SDL-1.2.14.org/src/video/windib/SDL_dibevents.c SDL-1.2.14/src/video/windib/SDL_dibevents.c
--- SDL-1.2.14.org/src/video/windib/SDL_dibevents.c Mon Feb 15 11:49:09 2010
+++ SDL-1.2.14/src/video/windib/SDL_dibevents.c Mon Feb 15 11:51:15 2010
@@ -328,12 +328,13 @@
extern int mouse_relative;
extern int posted;
POINT mouse;
POINT mouse, originalMouse;
#ifdef _WIN32_WCE
if ( !GetCursorPos(&mouse) && !GetLastStylusPos(&mouse) ) return;
#else
if ( !GetCursorPos(&mouse) ) return;
#endif
originalMouse = mouse;
if ( mouse_relative ) {
POINT center;
@@ -345,7 +346,11 @@
mouse.y -= center.y;
if ( mouse.x || mouse.y ) {
SetCursorPos(center.x, center.y);
This bug report was migrated from our old Bugzilla tracker.
Reported in version: 1.2.14
Reported for operating system, platform: Windows 7, All
Comments on the original bug report:
On 2010-02-20 12:46:13 +0000, wrote:
On 2011-03-07 14:12:09 +0000, Sam Lantinga wrote:
The text was updated successfully, but these errors were encountered: