Join GitHub today
GitHub is home to over 20 million developers working together to host and review code, manage projects, and build software together.
Fix return from fullscreen for linux/gnome not returning to previous size. #3004
Seems I am not the only one with this issue. Not sure the exact test cases that cause this issue but under linux/gnome when returning from fullscreen mode to window mode. There is a window resize event sent to XBMC after exiting fullscreen that sets it to the size of current desktop resolution after setting it to the previous window size, resulting in an unwanted maximized window. This simple fix just checks if the resize event is the same dimensions as the desktop resolution while NOT in fullscreen to avoid a resize. Has only been tested on linux mint 15 (cinnamon). Since this case should never happen anyways seems like a reasonable quick fix. Possible to cause resize issues with hidden task bars when maximizing the widow though, this is untested.
This comment has been minimized.
This comment has been minimized.Show comment Hide comment
what I meant is that application should not bothered with special cases going just wrong on a single platform. I think the reason for this issue is SDL. It operates with three windows and WinEventsSDL may catch a ConfigureNotify event from an invisible one.
This issue might already be fixed by the drop SDL branch which you can try in a slightly modified form here:
In case you want to fix this for the current version, I would suggest that you filter the event in here:
Note that it may desired to have the windowed size the same as full screen.
I do agree it was just a quick fix and that a case where it would be desired to have the resolution the same as the fullscreen while not in fullscreen is possible. It was less likely then the resize problem that currently existed. It would always be better to solve the root of the problem then filtering it out anyways.
This branch does indeed solve the problem.
commented and squashed
On Fri, Aug 2, 2013 at 2:49 PM, Rainer Hochecker