Skip to content
Browse files

Fix slowdown during startup scenario list loading #1721

(the one that could be averted by wiggling the mouse)
  • Loading branch information...
SvenTwo committed Jul 12, 2017
1 parent 57c0aac commit 8dffeadc56ca8584fa909ef42a74c54bbab8e608
Showing with 3 additions and 1 deletion.
  1. +3 −1 src/gui/C4StartupScenSelDlg.cpp
@@ -1201,7 +1201,9 @@ bool C4ScenarioListLoader::DoProcessCallback(int32_t iProgress, int32_t iMaxProg
// callback to dialog
if (C4StartupScenSelDlg::pInstance) C4StartupScenSelDlg::pInstance->ProcessCallback();
// process callback - abort at a few ugly circumstances...
if (!Application.ScheduleProcs() // WM_QUIT message?
// schedule with 1ms delay to force event processing
// (delay 0 would be nice, but isn't supported properly by our Windows implementation of ScheduleProcs)
if (!Application.ScheduleProcs(1) // WM_QUIT message?
|| !C4StartupScenSelDlg::pInstance // host dialog removed?
|| !C4StartupScenSelDlg::pInstance->IsShown() // host dialog closed?
) return false;

0 comments on commit 8dffead

Please sign in to comment.
You can’t perform that action at this time.