Fix bug where detaching loaded but hidden video had broken results.

Originally committed to SVN as r3798.
This commit is contained in:
Thomas Goyne 2009-11-17 01:37:18 +00:00
parent 3719227e9e
commit feb77217c7

View file

@ -631,8 +631,6 @@ void FrameMain::InitContents() {
//SetSizer(MainSizer); //SetSizer(MainSizer);
// Set display // Set display
StartupLog(_T("Set display mode"));
SetDisplayMode(0,0);
StartupLog(_T("Perform layout")); StartupLog(_T("Perform layout"));
Layout(); Layout();
StartupLog(_T("Set focus to edting box")); StartupLog(_T("Set focus to edting box"));
@ -894,7 +892,7 @@ void FrameMain::SetDisplayMode(int video, int audio) {
MainSizer->Layout(); MainSizer->Layout();
Layout(); Layout();
Show(true); Show(true);
VideoContext::Get()->UpdateDisplays(true); if (showVideo) VideoContext::Get()->UpdateDisplays(true);
Thaw(); Thaw();
} }
@ -1286,6 +1284,7 @@ void FrameMain::DetachVideo(bool detach) {
if (!detachedVideo) { if (!detachedVideo) {
detachedVideo = new DialogDetachedVideo(this, videoBox->videoDisplay->GetClientSize()); detachedVideo = new DialogDetachedVideo(this, videoBox->videoDisplay->GetClientSize());
detachedVideo->Show(); detachedVideo->Show();
VideoContext::Get()->UpdateDisplays(true);
} }
} }
else if (detachedVideo) { else if (detachedVideo) {