From 344674b8893eca8963ae4d9c541cb10f66d9d55a Mon Sep 17 00:00:00 2001 From: Nemirtingas Date: Tue, 3 Sep 2019 19:21:42 +0200 Subject: [PATCH] revert of "Should fix the cursor until we draw our own cursor." --- overlay_experimental/steam_overlay.cpp | 17 ++--------------- 1 file changed, 2 insertions(+), 15 deletions(-) diff --git a/overlay_experimental/steam_overlay.cpp b/overlay_experimental/steam_overlay.cpp index 49cfe9b..69d90b6 100644 --- a/overlay_experimental/steam_overlay.cpp +++ b/overlay_experimental/steam_overlay.cpp @@ -125,7 +125,6 @@ void Steam_Overlay::ShowOverlay(bool state) #ifdef __WINDOWS__ static RECT old_clip; - static BOOL show_cursor = FALSE; if (state) { @@ -155,24 +154,12 @@ void Steam_Overlay::ShowOverlay(bool state) clipRect.bottom -= borderWidth; ClipCursor(&clipRect); - - CURSORINFO cinfo; - cinfo.cbSize = sizeof(cinfo); - GetCursorInfo(&cinfo); - show_cursor = cinfo.flags == CURSOR_SHOWING; - - POINT pos; - pos.x = cliRect.right/2; - pos.y = cliRect.bottom/2; - ClientToScreen(game_hwnd, &pos); - SetCursorPos(pos.x, pos.y); - while (ShowCursor(TRUE) < 0); + ImGui::GetIO().MouseDrawCursor = true; } else { ClipCursor(&old_clip); - if (!show_cursor) - while (ShowCursor(FALSE) >= 0); + ImGui::GetIO().MouseDrawCursor = false; } #else