From 362c4bd32a8e1d9ad3ca5e87e60bcae081c0a026 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Daniel=20=C3=96nnerby?= Date: Thu, 13 Nov 2008 20:18:49 +0000 Subject: [PATCH] Fixed another racing condition in Application and ApplicationThread. --- src/win32cpp/Application.cpp | 2 +- src/win32cpp/ApplicationThread.cpp | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/src/win32cpp/Application.cpp b/src/win32cpp/Application.cpp index 9ebe745ee..ff3bb8bb9 100644 --- a/src/win32cpp/Application.cpp +++ b/src/win32cpp/Application.cpp @@ -59,6 +59,7 @@ Application Application::sMainApplication; , appThread(NULL) , trayIconManager(NULL) { + this->appThread = new ApplicationThread(); } ///\brief @@ -125,7 +126,6 @@ void Application::Run(TopLevelWindow& mainWindow) mainWindow.Initialize(); } - this->appThread = new ApplicationThread(); this->appThread->Initialize(); this->trayIconManager = new TrayIconManager; diff --git a/src/win32cpp/ApplicationThread.cpp b/src/win32cpp/ApplicationThread.cpp index 46340a8e1..1073e9002 100644 --- a/src/win32cpp/ApplicationThread.cpp +++ b/src/win32cpp/ApplicationThread.cpp @@ -131,6 +131,7 @@ void ApplicationThread::Initialize() // Create helper window this->helperWindow = new ApplicationThread::HelperWindow(); this->helperWindow->Initialize(); + this->NotifyMainThread(); }