Make sure window is shown before trying to show it full screen, see #18942

This commit is contained in:
Paul Cornett
2020-10-13 09:24:08 -07:00
parent 8a67a78195
commit 3bad6ecf0b

View File

@@ -910,6 +910,11 @@ bool wxTopLevelWindowGTK::ShowFullScreen(bool show, long)
if (show == m_fsIsShowing)
return false; // return what?
// documented behaviour is to show the window if it's still hidden when
// showing it full screen
if (show)
Show();
m_fsIsShowing = show;
#if defined(GDK_WINDOWING_X11) && !defined(__WXGTK4__)
@@ -992,11 +997,6 @@ bool wxTopLevelWindowGTK::ShowFullScreen(bool show, long)
}
#endif // GDK_WINDOWING_X11
// documented behaviour is to show the window if it's still hidden when
// showing it full screen
if (show)
Show();
return true;
}