From af26c945b10c400f9720dbb29857876867a57c35 Mon Sep 17 00:00:00 2001 From: Connor Garey Date: Sat, 14 Dec 2024 22:30:17 +0000 Subject: [PATCH] Fix for "shadPS4" not being given on Linux volume mixers (#1789) --- src/sdl_window.cpp | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/sdl_window.cpp b/src/sdl_window.cpp index f6b57436..4b13844b 100644 --- a/src/sdl_window.cpp +++ b/src/sdl_window.cpp @@ -2,6 +2,7 @@ // SPDX-License-Identifier: GPL-2.0-or-later #include +#include #include #include #include @@ -68,6 +69,9 @@ static Uint32 SDLCALL PollController(void* userdata, SDL_TimerID timer_id, Uint3 WindowSDL::WindowSDL(s32 width_, s32 height_, Input::GameController* controller_, std::string_view window_title) : width{width_}, height{height_}, controller{controller_} { + if (!SDL_SetHint(SDL_HINT_APP_NAME, "shadPS4")) { + UNREACHABLE_MSG("Failed to set SDL window hint: {}", SDL_GetError()); + } if (!SDL_Init(SDL_INIT_VIDEO)) { UNREACHABLE_MSG("Failed to initialize SDL video subsystem: {}", SDL_GetError()); }