From 7e9c3052f88dcc8eedefafc1e7035f46b3be873b Mon Sep 17 00:00:00 2001 From: raven02 Date: Fri, 3 May 2013 06:27:46 +0800 Subject: [PATCH] Hide mouse cursor in full screen mode --- Windows/WndMainWindow.cpp | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/Windows/WndMainWindow.cpp b/Windows/WndMainWindow.cpp index 360ba30bc..c3825652a 100644 --- a/Windows/WndMainWindow.cpp +++ b/Windows/WndMainWindow.cpp @@ -1084,6 +1084,9 @@ namespace MainWindow void _ViewNormal(HWND hWnd) { + ShowCursor(TRUE); + SetCursor(LoadCursor(NULL, IDC_ARROW)); + ClipCursor(NULL); // put caption and border styles back DWORD dwOldStyle = ::GetWindowLong(hWnd, GWL_STYLE); DWORD dwNewStyle = dwOldStyle | WS_CAPTION | WS_THICKFRAME; @@ -1107,6 +1110,9 @@ namespace MainWindow void _ViewFullScreen(HWND hWnd) { + ShowCursor(FALSE); + SetCursor(NULL); + ClipCursor(&g_normalRC); // keep in mind normal window rectangle ::GetWindowRect(hWnd, &g_normalRC);