From 16bb7e252a00d9d777c441ad788e32b99949f810 Mon Sep 17 00:00:00 2001 From: Moritz Bunkus Date: Tue, 7 Jun 2005 14:40:26 +0000 Subject: [PATCH] Check the saved window coordinates. If the window is minimized when mmg is closed then the coordinates are negative. Moving the window to that position upon restart will make it invisible. --- ChangeLog | 4 ++++ src/mmg/mmg.cpp | 4 +++- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/ChangeLog b/ChangeLog index 6f6370510..dd445a9bc 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,9 @@ 2005-06-07 Moritz Bunkus + * mmg: bug fix: If mmg was minimized when it was closed (e.g. with + Windows' "Show desktop" function) then it didn't show up after a + restart and could only be shown by maximizing it. + * mkvmerge: bug fix: If a OGM style chapter file contains empty chapter names ('CHAPTER01NAME=' without something after the '=') then this chapter's timecode is used as the name instead of diff --git a/src/mmg/mmg.cpp b/src/mmg/mmg.cpp index af044a710..261dfcc05 100644 --- a/src/mmg/mmg.cpp +++ b/src/mmg/mmg.cpp @@ -780,7 +780,9 @@ mmg_dialog::mmg_dialog(): cfg = wxConfigBase::Get(); cfg->SetPath(wxT("/GUI")); if (cfg->Read(wxT("window_position_x"), &window_pos_x) && - cfg->Read(wxT("window_position_y"), &window_pos_y)) + cfg->Read(wxT("window_position_y"), &window_pos_y) && + (0 < window_pos_x) && (0xffff > window_pos_x) && + (0 < window_pos_y) && (0xffff > window_pos_y)) Move(window_pos_x, window_pos_y); cfg->Read(wxT("warned_chapterditor_not_empty"), &warned_chapter_editor_not_empty, false);