From b0b46fd075e9e8f735ed6cee184c1b912863b401 Mon Sep 17 00:00:00 2001 From: WinterSnowfall Date: Sun, 16 Jul 2023 18:46:19 +0300 Subject: [PATCH] [d3d9] Don't show/hide a software cursor --- src/d3d9/d3d9_cursor.cpp | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/src/d3d9/d3d9_cursor.cpp b/src/d3d9/d3d9_cursor.cpp index 798104b3f..16ec41d60 100644 --- a/src/d3d9/d3d9_cursor.cpp +++ b/src/d3d9/d3d9_cursor.cpp @@ -16,7 +16,11 @@ namespace dxvk { BOOL D3D9Cursor::ShowCursor(BOOL bShow) { - ::SetCursor(bShow ? m_hCursor : nullptr); + if (likely(m_hCursor != nullptr)) + ::SetCursor(bShow ? m_hCursor : nullptr); + else + Logger::debug("D3D9Cursor::ShowCursor: Software cursor not implemented."); + return std::exchange(m_visible, bShow); } @@ -63,4 +67,4 @@ namespace dxvk { } #endif -} \ No newline at end of file +}