mirror of
https://git.eden-emu.dev/archive/citron
synced 2026-03-23 01:56:08 -04:00
fix(gamescope): Add Boolean for Gamescope
Signed-off-by: Collecting <collecting@noreply.localhost>
This commit is contained in:
@@ -136,4 +136,15 @@ namespace UISettings {
|
||||
config.value(QStringLiteral("microProfileDialogGeometry")).toByteArray();
|
||||
}
|
||||
|
||||
bool IsGamescope() {
|
||||
#ifdef __linux__
|
||||
static const bool is_gamescope = !qgetenv("GAMESCOPE_WIDTH").isEmpty() ||
|
||||
qgetenv("XDG_CURRENT_DESKTOP") == "gamescope" ||
|
||||
!qgetenv("STEAM_DECK").isEmpty();
|
||||
return is_gamescope;
|
||||
#else
|
||||
return false;
|
||||
#endif
|
||||
}
|
||||
|
||||
} // namespace UISettings
|
||||
|
||||
Reference in New Issue
Block a user