Call SetCursor always on the UI thread.

Fixes #2862.
This commit is contained in:
Unknown W. Brackets committed 2013-07-21 02:21:50 -07:00
1 parent 6ccaed10f6
commit 8717e745a8
1 file changed
+6 -1
+6 -1
View File
@@ -88,6 +88,8 @@ namespace MainWindow
LRESULT CALLBACK DisplayProc(HWND, UINT, WPARAM, LPARAM);
LRESULT CALLBACK About(HWND, UINT, WPARAM, LPARAM);
const UINT WM_USER_SAVESTATE_FINISH = WM_USER + 100;
HWND GetHWND() {
return hwndMain;
}
@@ -1001,6 +1003,9 @@ namespace MainWindow
SetForegroundWindow(hwndMain);
break;
case WM_USER_SAVESTATE_FINISH:
SetCursor(LoadCursor(0, IDC_ARROW));
break;
case WM_MENUSELECT:
// Unfortunately, accelerate keys (hotkeys) shares the same enabled/disabled states
@@ -1241,7 +1246,7 @@ namespace MainWindow
void SaveStateActionFinished(bool result, void *userdata)
{
SetCursor(LoadCursor(0, IDC_ARROW));
PostMessage(hwndMain, WM_USER_SAVESTATE_FINISH, 0, 0);
}
HINSTANCE GetHInstance()