Added better support for kubuntu and fixed some issues with telemetry.

This commit is contained in:
2026-09-09 22:35:13 +02:00
parent 6e6219107e
commit 290d1a5383
8 changed files with 587 additions and 65 deletions

View File

@@ -26,6 +26,10 @@ from .gamebox import (
)
from .paths import AppPaths
from .settings import Settings
from .system_identity import (
detect_distribution_id as _detect_distribution_id,
is_running_inside_steam_runtime as _is_running_inside_steam_runtime,
)
from .umu import find_umu_launcher
@@ -468,7 +472,14 @@ def run_game(
if use_gamebox:
gamescope_path = None
game_size = None
if settings.allow_window_resizing:
if settings.allow_window_resizing and launcher_inside_steam_runtime():
print(
"Warning: resizable Gamescope was disabled because the launcher "
"is already inside Steam Runtime; using a fixed game window.",
file=sys.stderr,
flush=True,
)
elif settings.allow_window_resizing:
gamescope_environment = os.environ.copy()
gamescope_environment.update(environment)
gamescope_path = find_gamescope(gamescope_environment)
@@ -714,11 +725,13 @@ def _proton_environment(
def detect_distribution_id() -> str:
"""Return the freedesktop distribution ID without invoking distro tools."""
try:
value = platform.freedesktop_os_release().get("ID", "")
except OSError:
return ""
return value.strip().casefold()
return _detect_distribution_id()
def launcher_inside_steam_runtime() -> bool:
"""Return whether this launcher process is nested in Steam Runtime."""
return _is_running_inside_steam_runtime()
def is_cachyos_host(