We are currently migrating Bugzilla to GitHub issues.
Any changes made to the bug tracker now will be lost, so please do not post new bugs or make changes to them.
When we're done, all bug URLs will redirect to their equivalent location on the new bug tracker.

Bug 347

Summary: Bogus mouse motion event on window creation...
Product: SDL Reporter: Ryan C. Gordon <icculus>
Component: eventsAssignee: Ryan C. Gordon <icculus>
Status: RESOLVED WORKSFORME QA Contact: Sam Lantinga <slouken>
Severity: normal    
Priority: P1    
Version: 1.2.11   
Hardware: x86   
OS: Linux   

Description Ryan C. Gordon 2006-10-18 01:02:20 UTC
(X11 driver.)

It appears that if the system cursor happens to be inside the window built by SDL_SetVideoMode() upon creation, SDL will generate a bogus mouse motion event.

   http://www.libsdl.org/pipermail/sdl/2006-October/076927.html

(Contrary to original post, it isn't related to SDL_ShowCursor() or input grabbing, although input grabbing guarantees that it will trigger, since it moves the cursor into the window.)

The default Gnome window manager, metacity, puts all new windows in the top left corner of the screen. This makes it easy to reproduce this issue.

--ryan.
Comment 1 Ryan C. Gordon 2007-06-02 13:58:57 UTC
Bumping a bunch of bugs to Priority 1 for consideration for the 1.2.12 release.

--ryan.

Comment 2 Ryan C. Gordon 2007-07-05 02:18:41 UTC
Updated mailing list URL:

   http://lists.libsdl.org/pipermail/sdl-libsdl.org/2006-October/058402.html

Hmm, I can't reproduce this any more, or I misunderstood the original report.

--ryan.