Please sign in to comment.
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fixed bug 875 - Title bar unresponsive after video mode change
Gabriel Gambetta 2009-11-04 04:51:46 PST If you change the video mode while holding the mouse button down, and then click on the window, you can't move the mouse pointer over the title bar or the close window button. It turns out WinMessage in SDL_Sysevents.c is using a static int mouse_pressed to keep track of whether it should call SetCapture() and ReleaseCapture(). Since it's static and initialized only once, it isn't cleared when the video mode changed, so there's a kind of one-off error and SetCapture() and ReleaseCapture() aren't being called when they should. Here's a patch - I just made that int accessible from the outside and reset it to 0 in SDL_SetVideoMode, wrapped in #ifdef WIN32. Suggestions on how to make this more elegant are welcome.
- Loading branch information
Showing with 14 additions and 5 deletions.