Make the cool stuff in r4606 a little less cool, but apparently wxGtk doesn't let you freeze invisible windows and get away with it, so we'll have to live with a little extra flicker.

Originally committed to SVN as r4636.
This commit is contained in:
Niels Martin Hansen 2010-06-28 22:15:40 +00:00
parent 6589d258ce
commit 37cd66c950
1 changed files with 6 additions and 5 deletions

View File

@ -213,8 +213,8 @@ FrameMain::FrameMain (wxArrayString args)
PerformVersionCheck(false);
StartupLog(_T("Display main window"));
Freeze();
Show();
Freeze();
SetDisplayMode(1, 1);
Thaw();
@ -856,8 +856,9 @@ void FrameMain::SetDisplayMode(int video, int audio) {
showVideo = sv;
showAudio = sa;
// Stop
Freeze();
bool didFreeze = !IsFrozen();
if (didFreeze) Freeze();
VideoContext::Get()->Stop();
// Set display
@ -871,9 +872,9 @@ void FrameMain::SetDisplayMode(int video, int audio) {
MainSizer->RecalcSizes();
MainSizer->Layout();
Layout();
Show(true);
if (showVideo) VideoContext::Get()->UpdateDisplays(true);
Thaw();
if (didFreeze) Thaw();
}
/// @brief Update title bar