diff --git a/src/common/config.cpp b/src/common/config.cpp index f23b9d652..26c2ad060 100644 --- a/src/common/config.cpp +++ b/src/common/config.cpp @@ -11,6 +11,7 @@ namespace Config { static bool isNeo = false; static bool isFullscreen = false; +static bool hideCursor = true; static u32 screenWidth = 1280; static u32 screenHeight = 720; static s32 gpuId = -1; // Vulkan physical device index. Set to negative for auto select @@ -54,6 +55,10 @@ bool isFullscreenMode() { return isFullscreen; } +bool isHideCursor() { + return hideCursor; +} + u32 getScreenWidth() { return screenWidth; } diff --git a/src/common/config.h b/src/common/config.h index 0a3b4905e..c9c0e9a3f 100644 --- a/src/common/config.h +++ b/src/common/config.h @@ -13,6 +13,7 @@ void save(const std::filesystem::path& path); bool isNeoMode(); bool isFullscreenMode(); +bool isHideCursor(); std::string getLogFilter(); std::string getLogType(); diff --git a/src/sdl_window.cpp b/src/sdl_window.cpp index 05bd190b7..5baf0982a 100644 --- a/src/sdl_window.cpp +++ b/src/sdl_window.cpp @@ -45,7 +45,7 @@ WindowSDL::WindowSDL(s32 width_, s32 height_, Input::GameController* controller_ } SDL_SetWindowFullscreen(window, Config::isFullscreenMode()); - CursorVisibility(true); + CursorVisibility(Config::isHideCursor()); #if defined(SDL_PLATFORM_WIN32) window_info.type = WindowSystemType::Windows;