Merge main into add-compose-previews

This commit is contained in:
xXJsonDeruloXx committed 2026-10-10 13:09:59 -04:00
commit 3f4405931a
408 files changed
+51662 -5179

No files matched your search

+176 -26
View File
@@ -1,41 +1,191 @@
# Agent control
The debug APK exposes a ContentProvider at `content://com.droiddeck.launcher.agent` and an Activity for starting sessions. Android's shell-only `DUMP` permission protects both. They are absent from release APKs.
`tools/droiddeckctl` drives DroidDeck on a real device over ADB, for agents and scripts that test
the app end to end: start and stop sessions, launch and quit Steam games, wait for a game to have
focus, send input, inspect the app's UI and gamescope's windows, run commands inside the session,
and collect logs, screenshots and recordings. `tools/droiddeck-scenario` repeats a scripted test
and reports every run.
Build and install the debug APK:
## How it works
- **The provider** `content://com.droiddeck.launcher.agent` (`agent/AgentBridgeProvider.kt`)
answers each command with JSON. It and the session-start Activity (`AgentStartActivity`) are in
every build and require `android.permission.DUMP`, held by the ADB shell and privileged or
explicitly granted callers. The provider checks the calling permission before decoding requests.
- **The guest agent** `droiddeck-agent` runs inside every session (started by
`droiddeck-session`). It runs commands with the session's own environment, publishes gamescope's
focus, and talks to the Steam client's DevTools, which only accepts guest processes. The app and
the agent exchange request and answer files under the session root (`files/session/agent`).
- **The UI dump** reads the app's Compose semantics from inside the app (`agent/AgentUi.kt`), so it
works on every display and window. UI Automator, by contrast, dumps whichever window has focus,
which on a dual-screen device is often another app's.
## Access
Player controls and observations work over authorized ADB on any build: `state`, `start`, `stop`,
`resume`, `wait`, `launch`, `quit`, `focus`, `input`, `ui`, `logs`, `screenshot`, `record`, `displays`,
`wake`, and `access`.
**Setup > Session > Debugging tools** is off by default in every build, including debug builds.
It enables `run`, `guest`, `cdp`, all `env` operations, `override`, and `prefs`. The toggle switches
directly without a confirmation dialog. The bridge refuses to change it through `ui` or preference
writes. The existing preference key, `setting-agent-commands` test tag, JSON command names, and
`AGENT_COMMANDS_DISABLED` error code are unchanged. Refusals exit 7; `droiddeckctl access` reports
whether commands are enabled.
Disabling the toggle clears queued and persistent agent environment settings and installed binary
overrides. Disabled settings cannot apply at the next session start. Already running commands and
effects already applied to a session are not undone; stop and restart that session to discard them.
Authorized command execution runs inside the runtime containing Steam's saved login. CDP evaluates
JavaScript in the authenticated Steam client, and preferences can contain private values. These
capabilities remain unrestricted when enabled: the toggle is an explicit opt-in, not credential
isolation or a sandbox against the authorized caller. Main already supported arbitrary guest
programs through `run`; restricting credential access would require addressing that route too.
ADB access remains a trust boundary, and ADB input can operate the device's own toggle.
The helper exchanges private files with the app and adds no network listener. The guarded Steam
DevTools port is bound to loopback and accepts only peers with a fresh private registration for a
live socket descriptor, matching socket inode, destination port, and address family. The existing
x86_64 Decky loader exception remains: that mode does not enable the guest-only acceptance guard.
Requests are limited to 256 KiB of encoded JSON. Guest responses and DevTools messages are limited
to 1 MiB; provider replies above 384 Ki characters return `RESPONSE_TOO_LARGE` to avoid overflowing
Binder. Command output retains at most 256 KiB per stream while continuing to drain both streams.
Timeouts must be finite, positive, and no greater than 600 seconds, and terminate the command's
process group. Override installation refuses path traversal and symbolic links.
Automatic process logs record environment keys and argument counts rather than values or full
argument lists. UI nodes marked as passwords redact text, editable text, descriptions, and state
text. This does not redact arbitrary authorized command results, CDP data, preferences, or screen
captures. Scenario directories are owner-only and JSON reports are written with mode 0600. Review
artifacts before sharing; a live `logs` pull copies the current folder without a fresh export scrub.
## Device selection and output
The CLI resolves one authorized device using `ADB_SERIAL` or `ANDROID_SERIAL` when set. Otherwise it
de-duplicates transports that report the same device serial and asks for an explicit serial if
multiple devices remain. Pass `--serial` before the command to choose directly; set `ADB` (or pass
`--adb`) to choose an adb executable. `tools/deploy_local.sh` uses the same resolver.
Every command writes one JSON object to stdout and its resolved serial to stderr. Exit codes: 0
success, 2 invalid or rejected command, 3 ADB or device error, 4 session error, 5 timeout, 6
artifact or file error, 7 debugging tools disabled.
## Commands
```sh
./gradlew assembleDebug --console=plain
adb install -r app/build/outputs/apk/debug/app-debug.apk
```
The provider can also be called directly for state, stop, and resume:
```sh
adb shell content call --uri content://com.droiddeck.launcher.agent --method state
adb shell content call --uri content://com.droiddeck.launcher.agent --method stop
```
Start requests go through `tools/droiddeckctl`, which launches the protected debug Activity from the ADB shell. Calling the provider's `start` method directly returns an error because a background provider cannot reliably open the session screen.
The host CLI resolves one authorized device using `ADB_SERIAL` or `ANDROID_SERIAL` when set. Otherwise it deduplicates transports that report the same device serial and asks for an explicit serial if multiple devices remain.
```sh
tools/droiddeckctl state --json
tools/droiddeckctl start steam
tools/droiddeckctl wait ready --timeout 90
tools/droiddeckctl state # schema 2, below
tools/droiddeckctl start steam --wait # --ui desktop, --url steam://..., --timeout
tools/droiddeckctl start steam --wait --reuse # keep a Steam session that is already up
tools/droiddeckctl start desktop
tools/droiddeckctl run /usr/bin/foo -- arg1 arg2
tools/droiddeckctl wait ready|idle|failed # --timeout (default 90 s)
tools/droiddeckctl stop
tools/droiddeckctl resume
tools/droiddeckctl launch 489830 --wait # Steam game by app id; --wait = until it has focus
tools/droiddeckctl wait focused 489830 # gamescope focuses it AND Steam lists it focusable
tools/droiddeckctl wait game # any app but the Steam client (769) has focus
tools/droiddeckctl quit 489830 # Steam's TerminateApp, then SIGTERM/SIGKILL
tools/droiddeckctl focus # focus properties and every Xwayland server's windows
tools/droiddeckctl input key ENTER # names (ESC, F1, UP, A...) or evdev codes; --mod CTRL
tools/droiddeckctl input text 'hello world' # as US-layout keys; --commit for text-input
tools/droiddeckctl input tap 640 360 # session output pixels; --space fraction for 0..1
tools/droiddeckctl input swipe 100 600 100 100 --duration 400
tools/droiddeckctl input pad a # a b x y lb rb start select guide qam up down left right
tools/droiddeckctl input stick left 0 -1 --hold 500
tools/droiddeckctl input trigger right 1.0
tools/droiddeckctl ui dump # tagged, labelled and clickable nodes; --all for every node
tools/droiddeckctl ui click rail-steam # by test tag
tools/droiddeckctl ui click --match "Play" # by text or description; --index for the nth match
tools/droiddeckctl ui set-text some-field --text abc
tools/droiddeckctl guest -- xprop -root GAMESCOPE_FOCUSED_APP # --timeout --env K=V --cwd --stdin --check
tools/droiddeckctl cdp targets
tools/droiddeckctl cdp eval 'SteamClient.Apps.GetMyRunningApps?.()' # --target, --no-await
tools/droiddeckctl env set DXVK_HUD=fps # next session only; --persistent until cleared
tools/droiddeckctl env list
tools/droiddeckctl env clear [next|persistent|all]
tools/droiddeckctl override gamescope ./gamescope # first on the next session's PATH, removed after it
tools/droiddeckctl prefs get session
tools/droiddeckctl prefs set session some_key true --type bool # returns the previous value
tools/droiddeckctl logs latest ./session-artifacts
tools/droiddeckctl screenshot ./screen.png
tools/droiddeckctl screenshot ./screen.png --display 4
tools/droiddeckctl record ./clip.mp4 --seconds 8 --display 0
tools/droiddeckctl displays # logical ids, names, sizes, capture ids
tools/droiddeckctl wake # wake the screen, dismiss the keyguard
```
Every command writes JSON to stdout and reports its resolved ADB serial to stderr. Exit codes are 0 for success, 2 for invalid or rejected commands, 3 for ADB/device errors, 4 for session failures, 5 for timeouts, and 6 for artifact or file errors. Set `ADB` to select an adb executable (or pass `--adb`); pass `--serial` before the command to select a device directly.
A sleeping device suspends the session and hides the app's windows from `ui dump`; `wake` first.
`start` accepts `steam` or `desktop`. Steam starts in Big Picture by default; `--ui desktop` selects the client's desktop UI, and `--url steam://...` passes a client URL. Use `--wait` to wait for `READY` as part of `start`. `run` accepts a program path and optional guest arguments.
`input` needs a session that has drawn its first frame. Pad input goes through the session screen's
virtual pad, the same one the on-screen controls drive, so games that ignore touch still respond.
`launch`, `quit` and `cdp` need a Steam session; `focus` and `wait focused` need gamescope (every
mode except the desktop).
The `state` response uses schema 1 and includes the build label, runtime version, session ID and phase, mode, requested program, suspend and first-frame state, output size, guest PID, failure details, and artifact paths. Phases are `IDLE`, `PREPARING`, `INSTALLING_RUNTIME`, `STARTING_COMPOSITOR`, `STARTING_GUEST`, `STARTING_STEAM`, `READY`, `SUSPENDED`, `STOPPING`, and `FAILED`. Each session also writes `events.jsonl` alongside its existing artifacts.
## State (schema 2)
`tools/deploy_local.sh` uses the same device resolver. If multiple distinct devices are connected, select one with `ADB_SERIAL` or `ANDROID_SERIAL`.
`state` returns `schema`, `build`, `appVersion`, `runtime {installed, version}`,
`agent {guest, guestFocus, commands}` and `session`:
- `id`, `phase`, `running`, `mode`, `program`, `steamUi`, `steamUrl`, `suspended`, `pip`,
`firstFrame`, `output` [w, h], `refreshHz`, `lastTransitionAt`, `guestPid`, `installing`
- `logDir`, `eventsFile`, `artifactsAvailable`, `artifactsComplete`, `failure {code, message, status}`
- `focus`: gamescope's focus as the guest agent last published it, or null:
`focusedApp`, `focusedWindow`, `focusableApps`, `baselayerAppIds`, `seq`, `t`.
Phases: `IDLE`, `PREPARING`, `INSTALLING_RUNTIME`, `STARTING_COMPOSITOR`, `STARTING_GUEST`,
`STARTING_STEAM`, `READY`, `SUSPENDED`, `STOPPING`, `FAILED`. Schema 2 only added `agent` and
`session.focus`; every schema 1 field is unchanged.
A game the player can see is `focusedApp == appId` **and** `appId in focusableApps`.
`GAMESCOPE_FOCUSABLE_WINDOWS` is what the Steam client orders the base layer from: a game missing
there stays behind the client's loading screen however healthy its window looks
(docs/development/steam-focus-debugging.md). `focus` returns the full snapshot, including each
server's windows with map state, override-redirect, app id, `WM_STATE`, pid, class, opacity and
`_NET_WM_STATE`.
## Events
Each session writes `events.jsonl` beside its other artifacts: the lifecycle (`session.created`,
`compositor.started`, `guest.exited`, ...) plus `agent.ready` (the guest agent is up),
`focus.changed` (the focused app, focusable apps or base-layer order changed) and
`agent.launch_requested`.
## UI test tags
Compose test tags are exposed as resource ids (`ui/TestTags.kt`), so both `ui dump` and UI
Automator show them:
| Tag | Where |
|---|---|
| `rail-steam`, `rail-games`, `rail-desktop`, `rail-store`, `rail-components`, `rail-android-apps`, `rail-setup`, `rail-updates` | the front end's rail |
| `play-steam` | Play on the Steam and Games pages |
| `setting-<key>` | every toggle and choice row, by its key (`setting-logs`, `setting-agent-commands`, ...) |
| `tab-<n>` | a page's tab strip (Setup's Overview, Controller, Session, Launcher...), by position |
| `drawer-tab-controller`, `-second_screen`, `-display`, `-effects`, `-games`, `-session` | the session drawer's pages |
| `drawer-stop`, `drawer-stop-confirm`, `drawer-stop-cancel` | stopping a session from the drawer |
## Scenarios
`tools/droiddeck-scenario` runs a JSON scenario: `setup` once, `steps` `repeat` times, `teardown`
once. Each run starts with `before` (typically `start steam --wait --reuse`, so a session that died
in one run, to a crash or the low-memory killer, is started again for the next) and ends with
`after`, whether it passed or not, so a failed run cannot leave a game running into the next. A list step is a droiddeckctl command line; `{"assert": "dotted.path", "equals"|"in"|
"contains"|"not"|"exists": ...}` checks the last answer; `{"sleep"}`, `{"screenshot"}` and
`{"record"}` do what they say. A failing run keeps a screenshot, the focus snapshot and the
session's logs in its folder, and `report.json` sums up the runs.
```sh
tools/droiddeck-scenario tools/scenarios/steam-game-focus.json --var appId=489830 --repeat 10 --keep-going
```
`tools/scenarios/steam-game-focus.json` launches a game, checks it has focus the way a player
sees it, and quits it: the test that catches a game left behind Steam's loading screen, which only
shows up in some fraction of launches. A game with a launcher of its own needs the launcher pressed
through first, since the launcher window carries the game's app id too:
`tools/scenarios/skyrim-launcher-focus.json` taps Skyrim's Play before checking.
+77
View File
@@ -0,0 +1,77 @@
# Added games
Windows games the user adds to DroidDeck's Games tab, each a non-Steam shortcut in the
Steam client that runs under `droiddeck-proton-arm64`. They show with the Custom chip.
## Adding
- **+ beside "Games N"** opens the in-app picker (`ExePickerDialog`, never Android's
system picker): the storage rows (Internal storage, each card, free space), then the
chosen storage from its root: every folder A-Z (dot-folders hidden, unreadable ones
greyed), `.exe` files only. The dialog keeps the width it opened with; long names are cut
short; it grows to 70% of the screen and scrolls. Red X closes; B / Back goes up a
folder, then closes.
- **Picking an exe** (`AddedGames.addExe`): the game it already is gets selected; an exe in
a listed game's folder becomes that game's target; otherwise the exe's folder becomes a
game (`files/added-exes.json`), registered at once (the listing the shortcuts writer
reads, and a running client over DevTools) and selected. A path the session cannot see
(internal storage maps to `/root/Storage`; cards only through Games folders, the Steam
library and store roots) is refused with one line.
- **"Add all games in this folder"** (top row of a folder with subfolders,
`AddedGames.addFolder`): each subfolder with an exe becomes a game with
`GameExePicker`'s best exe, kept as an entry of its own (not a Games folder); subfolders
already listed are counted, not added. A summary follows: games added, how many were
there already, one row per game (cover, name, exe, "?" when unsure); a row opens that
game's editor, straight on Target when unsure, with back to the summary.
- Games folders added before this (Steam settings had a Games section) keep listing their
games; there is no place to add a new one.
## Exe and name
`GameExePicker` walks up to five folders down (nearest first, 400 entries, no symlinks,
past installer / redistributable / extras folders), drops junk exe names and scores the
rest (named after the folder, Unreal `-Shipping` and `Binaries/Win64`, `bin/`, launchers
and junk lower, deeper lower, bigger higher). Best under 60, or a runner-up within 15:
uncertain, shown as "?". `GameIdentifier` / `PeVersionInfo` give the title (Steam
manifest by installdir, GOG info, the exe's version resource), else the folder name. The
shortcut appid is stored per folder at the first scan and never changes after.
## Editor
The ✎ on a Custom game's page (`AddedGameEditor`) mirrors Steam's Properties for a
non-Steam game: Name, Target (ranked exes, "?", Other exe… opening the picker in the
game's folder), Start in (automatic = the exe's folder), Launch options, Artwork (Cover,
Background, Logo, Icon, each with its thumbnail and source), and Remove (two presses; the
files stay; adding it again brings it back). `AddedGameEdits` writes each change through
the same shortcut: the listing (`name`, `exe`, `dir`, `launch`, `art`, the stored `appid`)
and, with a client running, `SetShortcutName` / `Exe` / `StartDir` / `LaunchOptions` and
`SetCustomArtworkForApp` / `SetShortcutIcon` on that appid. A new target updates the
existing shortcut; there is never a second one.
The shortcuts writer (`droiddeck-steam-shortcuts`) keeps what the user set in Steam: a
field follows the app only while Steam still has what the app last asked for. It records
Steam's AppName, Exe, StartDir and LaunchOptions in `.droiddeck-shortcuts.json`; a scan
takes a Steam-side edit over as the app's own once (`AddedGames.adoptSteamEdits`), so one
value holds on both sides.
## Art
Automatic: the game folder's own images, then Steam (the appid the files name, else a
store search whose result has the same name), then SteamGridDB, then the exe's icon. The
art chooser (an Artwork row) shows the game folder's images, Steam's official piece and
SteamGridDB's best few (fetched when it opens); a tap applies one, "Pick image…" takes a
file through the same picker (png, jpg, jpeg, webp, ico), "Reset to automatic" drops the
choice. A choice is a copy in `files/added-art/<appid>/chosen-<slot>.<ext>`, its source in
the preferences.
Setup › Launcher › Games holds the Artwork switch (automatic fetching) and the
SteamGridDB API key: the user's own, sealed with `CredentialCipher`, wins over the build's
(`BuildConfig.SGDB_API_KEY` from the `SGDB_API_KEY` secret); with neither, SteamGridDB is
skipped.
## Tests
`AddedExesTest`, `AddedGameEditsTest` (bulk add and skip, edits to the listing on a stable
appid, Steam-side read-back, art choice and reset), `AddedGamesCandidatesTest`,
`AddedGameArtLookupTest` (key precedence), `GameIdentifierTest`, `PickListingTest`, and
`tools/tests/test_steam_shortcuts.py` for the writer.
Binary file not shown.

After

Width:  |  Height:  |  Size: 1.6 MiB

+5 -5
View File
@@ -22,7 +22,7 @@ The script then unpacks them without hooks and checks what the binaries link. Li
the Desktop package normally brings (PyGObject, json-glib, fuse3 and others) are fetched too,
but only when their files are missing. Flathub is added as a per-user remote from a copy of
its `.flatpakrepo` carried in the script, so that step needs no network. Every store command
writes its output to `Download/DroidDeck/flatpak-<verb>.log`, next to the session logs. The
writes its output to `files/logs/tools/flatpak-<verb>.log`, next to the session logs. The
setup script also puts Flatpak's own error text in the failure message the app shows.
## bubblewrap without namespaces
@@ -51,8 +51,8 @@ The spawner also adds what the rootfs gives its own programs:
- **GPU.** Flathub's Mesa has Turnip only for DRM, and Adreno on Android is KGSL. The runtime's
own `libvulkan_freedreno.so` is bound in with the three libraries the Freedesktop runtime
lacks (`libdisplay-info`, SPIRV-Tools). Vulkan uses it, and Mesa's GL runs on it through Zink
(`MESA_LOADER_DRIVER_OVERRIDE=zink`). This is skipped for an app drawing into a desktop
composited by pixman, where Zink cannot present.
(`MESA_LOADER_DRIVER_OVERRIDE=zink`). This is skipped for an app drawing into a window on the
desktop, which KWin composites in software and where Zink cannot present.
- **Controllers.** The libraries in the rootfs's `/etc/ld.so.preload` (the session shim and the
fake evdev reader) go in through `LD_PRELOAD`, with the session's `dev` directory.
- **Browsers.** Firefox's child sandboxes are switched off (`MOZ_DISABLE_*_SANDBOX`), and
@@ -70,8 +70,8 @@ screen under gamescope. Under gamescope it passes `--nosocket=wayland --socket=x
opens behind gamescope. gamescope's own Wayland socket is no alternative: Chromium on Wayland
asks the render node it names for a DRM version, which KGSL cannot give, and aborts. The
launcher also starts a session bus when there is none. On the Linux desktop, the apps' exported
menu entries appear in the LXQt menu. While the desktop is composited by pixman, games are
wrapped through `droiddeck-gpu` like the rootfs's own.
menu entries appear in Plasma's launcher. Games are wrapped through `droiddeck-gpu` like the
rootfs's own, since the desktop composites in software.
## The store
+3 -3
View File
@@ -61,7 +61,7 @@ Why the current choices were made, from the history:
All runs on the AYN Thor (SD 8 Gen 2, Adreno 740, 1920x1080 top panel), Deck mode on, Force
fullscreen off, with a spike build of `feat/steam-native-output`. Each run sets
`Download/droiddeck-env` and starts the session with
`Android/data/com.droiddeck.launcher/files/droiddeck-env` and starts the session with
`am start -n com.droiddeck.launcher/.SessionActivity --es mode steam [--es steamUrl ...]`.
### Run 1: baseline (Resolution = Match screen, 1920x1080)
@@ -181,7 +181,7 @@ game. `--xwayland-count 2` and `STEAM_MULTIPLE_XWAYLANDS=1` went through `Downlo
## Two Xwayland servers by default (`feat/steam-dual-xwayland`)
Steam sessions now start gamescope with `--xwayland-count 2` and `STEAM_MULTIPLE_XWAYLANDS=1`.
`BL_XWAYLAND_COUNT=1` in `Download/droiddeck-env` goes back to one. The session script's
`BL_XWAYLAND_COUNT=1` in `Android/data/com.droiddeck.launcher/files/droiddeck-env` goes back to one. The session script's
root-window requests that are meant for the game (the drawer's live Force fullscreen,
`GAMESCOPE_FORCE_WINDOWS_FULLSCREEN`, and the resume watcher's `GAMESCOPE_RESTORE_FOCUS_WINDOW`)
go to both displays, `$DISPLAY` and `STEAM_GAME_DISPLAY_0`. gamescope reads both per server, so
@@ -222,7 +222,7 @@ reason "Force game windows fullscreen" existed. What it still did was make any g
Resolution differs from what it draws fight it (runs 4 and 5). The switch is gone from Steam
settings (Games) and the session drawer (Display), along with its preference, the
`BL_GAMESCOPE_FORCE_FULLSCREEN` flag, the `~/.droiddeck-fill` live watcher and the device report
line. `BL_GAMESCOPE_ARGS=--force-windows-fullscreen` in `Download/droiddeck-env` still passes the
line. `BL_GAMESCOPE_ARGS=--force-windows-fullscreen` in `Android/data/com.droiddeck.launcher/files/droiddeck-env` still passes the
flag for an experiment.
Device check (Thor): Alan Wake's American Nightmare with its 1280x720 Game Resolution runs on `:1`
+89
View File
@@ -0,0 +1,89 @@
# Steam session focus: how it works and how to debug it
Written 2026-10-07 after the "game opens behind Steam" reports (Skyrim SE, A Plague Tale:
Innocence, Burnout Paradise Remastered), fixed by gamescope patch 0114 (#401). It records what a
game needs to get focus in a Steam session and how to inspect a live session on a device, for the
next report that looks like this.
## How a game gets focus
The Steam session runs two Xwayland servers, as SteamOS does: the client on `:0`, games on `:1`
(`--xwayland-count 2`, `STEAM_MULTIPLE_XWAYLANDS=1` in `droiddeck-session`). Focus is decided in
three steps, and a window can drop out at each one:
1. **gamescope lists candidates.** For each server it collects windows that are mapped, of class
InputOutput, not fully transparent (`_NET_WM_WINDOW_OPACITY` above 0), not an overlay, and
carry an app id (`STEAM_GAME`). It publishes them on `:0`'s root as `GAMESCOPE_FOCUSABLE_APPS`
and `GAMESCOPE_FOCUSABLE_WINDOWS` (window, app id, pid triples). It leaves out of that published
list any window it believes is override-redirect, 1x1, or skip-taskbar-and-pager without
fullscreen.
2. **Steam picks an order.** The client reads those lists and writes
`GAMESCOPECTRL_BASELAYER_APPID`, for example `413091, 489830, 769`. When the running game has
no window in the focusable list, Steam puts itself (769) ahead of it.
3. **gamescope follows Steam.** The virtual connector strategy in a Steam session is
SteamControlled: the first app id in the base layer with a candidate window wins.
gamescope works from its own cached copy of each window's attributes, not from X. A window that X
shows mapped and tagged can still be missing in step 1 if that cache is stale.
## What the bug looked like
- On screen: Steam's black loading screen with only **ABORT GAME**, the game audible underneath.
Resume from the Steam menu does not help.
- `GAMESCOPE_FOCUSED_APP` stays `769`; `GAMESCOPECTRL_BASELAYER_APPID` has `769` ahead of the
game's app id; the game's window is missing from `GAMESCOPE_FOCUSABLE_WINDOWS`.
- On `:1` the game window is mapped, `WM_STATE` Normal, `STEAM_GAME` set, with no opacity,
`_NET_WM_STATE` or overlay properties.
- gamescope's `focus_info` shows server 1's own focus on the game while the global focus is Steam.
Cause: wine creates the game's window override-redirect and makes it managed before mapping it,
which sends no X event. gamescope read the attributes when the window was created and refreshed
`override_redirect` only from ConfigureNotify, so when its read came before wine's change it kept
the window as override-redirect and left it out of the list Steam reads. It is a race: Skyrim
failed about once in six launches on the Thor, on the first launch after a session start. Upstream
fixed it by taking the flag from MapNotify (ValveSoftware/gamescope 3829340, our patch 0114).
The launcher and the game both had window id `0x1c00003` on `:1`: with few clients on that server
the X server hands the game the launcher's freed id. That was not the cause (the game window came
7 s after the launcher's was destroyed), but it makes logs easy to misread.
## Inspecting a live session from adb
Everything below runs on the device as the app's uid (`su 10195` on the Thor, `u0_a195`), using
the rootfs's own binaries through its loader, so nothing has to enter proot:
```sh
R=/data/user/0/com.droiddeck.launcher/files/linuxfs
$R/usr/lib/ld-linux-aarch64.so.1 --library-path $R/usr/lib $R/usr/bin/xprop -display :0 -root \
GAMESCOPE_FOCUSED_APP GAMESCOPE_FOCUSABLE_WINDOWS GAMESCOPECTRL_BASELAYER_APPID
```
- The X servers answer on their **abstract** sockets (`\0/tmp/.X11-unix/X0`, `X1`); xprop finds
them by itself. The socket files under `linuxfs/tmp/.X11-unix` can be stale. Nothing answers
while the session is in the background or the screen is off (the session is stopped).
- The `VAR=… cmd` prefix does not survive `timeout` or `nohup`; put the command in a small
`/system/bin/sh` script in `/data/local/tmp` and run that.
- gamescope's focus state, written to the session's `session.log` (in
`Download/DroidDeck/<date>-NN-steam/`):
```sh
export XDG_RUNTIME_DIR=/data/user/0/com.droiddeck.launcher/files/.wayland-rt WAYLAND_DISPLAY=gamescope-0
G="$R/usr/lib/ld-linux-aarch64.so.1 --library-path $R/usr/lib $R/usr/bin/gamescopectl"
$G log_focus debug; $G focus_info
```
It prints the global focus, input, keyboard and override windows, the connector strategy, and
each server's own focus and keyboard focus. Disagreement between a server's focus and the
global one points at step 1 or 2 above.
- To tell a stale gamescope cache from a real X problem, make gamescope re-read the window: move it
by 1 px and back (ConfigureNotify), or unmap and map it (MapNotify). If the game comes forward,
gamescope's cache was wrong. A restack of a window already on top sends no event and proves
nothing.
- To test gamescope with a candidate binary without rebuilding the apk, put it in the rootfs (for
example `/opt/gstest/gamescope`, owned by the app's uid) and add
`PATH=/opt/gstest:/usr/local/bin:/usr/bin:/bin` to `Android/data/com.droiddeck.launcher/files/droiddeck-env`. The session log's
first lines name the gamescope that ran. Remove the line afterwards: the app stages its own
gamescope over `/usr/local/bin` at every session start.
- Never `pkill -f <pattern>` inside `su -c '…'`: the pattern matches that shell's own command line.
Killing `SkyrimSE.exe` that way took the whole session down. Kill by pid.
- Skyrim's menus take adb key events (`input keyevent 20` down, `66` enter); taps do nothing.
+128
View File
@@ -0,0 +1,128 @@
# Steam's touch controls
Drawer → Controller → **On-screen controls: Steam touch (beta)** replaces DroidDeck's own on-screen pad, in a
Steam session, with Steam's touch controller: the one the Steam Link apps use. Bindings, action
sets, per-game configs, Valve's touch templates, official and community touch configs and Steam
Cloud sync are all Steam's; DroidDeck draws the controls and turns touches into the controller's
input. The research behind this (how Steam Link's touch controller works, the experiments on the
Thor) is in `steam-touch-controller.md` on the `research/steam-touch-controller` branch.
## How it fits together
```
SteamTouchControls (overlay) → SteamTouchDevice (shared file) → libfakeinput /dev/hidraw17
↑ layout ↑ app / action set ↓ 0000:11fb
SteamTouchConfig (Steam's configs) ←─── output reports ←── Steam client: Mobile Touch controller
↓ Steam Input
virtual pad → game
```
- **The device.** Steam builds its touch controller (Steam Input's Mobile Touch type) for any HID
device with the ids 0000:11fb. libfakeinput offers one to the client as `/dev/hidraw17` beside
the Deck pad, with its sysfs written by `SteamDeckPad.prepare(touch = true)`. It needs a Generic
Desktop / Game Pad report descriptor: for a non-Valve vendor id the client ignores a vendor-page
device. Offered only with the Deck pad (Steam controller set to Deck);
`Download/droiddeck-no-steam-touch` turns it off.
- **The shared file** (`touchctl` in the session's pad directory, `FAKE_TOUCHCTL_RING`;
`SteamTouchDevice.kt` / `TouchRingFile` in `fakeinput_steam.cpp`). The app writes the 40-byte input
report under a seqlock, whether the device is plugged in, and the battery; libfakeinput writes
back what the client tells the device.
- **The report** (Steam Link's `CVirtualController`): bytes 0-7 button bits (the Deck's low word for
face buttons, bumpers, triggers, d-pad, Steam, menu buttons; 22/26 stick clicks; 46/47 sticks
touched; 27/19/20 trackpads touched; 32-39 macros; 48/49 one- and two-finger macros), 8-15
sticks (int16, Y up), 16-27 three trackpads, 28-33 accelerometer, 34-39 gyro (from PadMotion,
in the Deck's units).
- **Output reports from the client:** 4 = app id and action set (decides which layout is shown),
5/6 = action set layer added/removed, 1 = rumble (also sent to the app's vibration like any
pad's), 3 = a setting. Feature report 2 is the battery.
- **Plugging.** The device is plugged in only while Steam's controls are shown: always in a Steam
session with that choice, since a handheld's built-in pad would keep Auto off for good. Unplugging
ends the device's report stream (the client lets the controller go); either way libfakeinput
sends a udev event through `udevmon.c`'s stand-in monitor (`bl_udevmon_inject`), since the
sandbox gives the client no kernel uevents and its HID discovery would never look again.
## Layouts
`SteamTouchConfig.load` finds the game's touch config: the app's own saved config when the
configset (`configset_controller_mobile_touch.vdf`) points at one, otherwise the file the client's
console log says it loaded for the touch controller (a template, an official or a workshop config).
`touch_layout` in it is a hex `CVirtualControllerLayouts` protobuf: per action set, each control's
type, visibility, centre (fractions of the screen) and scale. Controls with no layout go where
Steam Link puts them by default; only controls the config's active sources bind are shown.
**Editing** (drawer → Steam touch layout → Edit): drag, pinch or −/+ to resize, Hide, Reset,
Cancel, Save. Save writes `touch_layout` into the game's autosave config
(`<account>/config/<appid>/controller_mobile_touch.vdf`, made from the config in use) and points the
configset at it, as the client does when Steam Link saves a layout; the device is then replugged so
the client reads it again. Steam Cloud uploads the file like any autosaved config (seen in
`userdata/<account>/241100/remotecache.vdf`).
## Verified on the Thor
- Big Picture: Steam shows "Controller Connected - Remote Play Touch Controller"; the Steam button
opens the menu, the d-pad moves focus.
- A game (Geometry Wars: Retro Evolved): Valve's Gamepad touch template loaded, the stick flies
the ship.
- A saved layout survives a session restart and was uploaded to Steam Cloud.
- Touch menus: a touch menu bound to a trackpad is drawn by Steam's own overlay when the trackpad
is held.
- Unplug and replug mid-session; two touch devices at once (research branch).
## Open
- Gyro: motion reaches the device's report, but a `gyro_to_joystick` binding did not move the stick
in the one test made (injected rates, sensors paused). Needs a look at what the client wants
(calibration, an enable setting).
- Custom touch icons (`SetTouchIconData` on Steam Link) are not drawn; controls use text labels.
- Not tried on a retail phone with SELinux enforcing (the Deck pad's sysfs works there).
## Icons, labels and colours
Each control shows what its binding carries, as Steam Link does: a binding is
`<action>, <label>, <icon>, <#foreground #background>` (e.g.
`xinput_button A, Attack, ghost_010_wpn_0070.png, #FFFFFF #AD0000`). Icons are looked up as Steam does:
the game's own `TouchMenuIcons` folder, then `tenfoot/resource/images/library/controller/binding_icons`
(459 icons). They are drawn as Steam draws binding icons: the icon multiplied by the foreground colour
on a disc of the background colour. A binding with no icon shows its label, else a glyph for what it
presses (LB, Esc, ⏎…), else the button's own name.
In the layout editor, **Icon** opens a picker for the selected control (a D-pad direction: the one
tapped): label, an icon from the game's own and Steam's library, foreground and background from Steam's
binding-icon palette. **Colour** sets the layout's colour and opacity. Save rewrites only those binding
strings in the game's touch config (byte for byte otherwise) along with `touch_layout`. Verified with
Castle Crashers (its config ships icons on the shoulders and stick click): icons drawn; A set to a knife,
white on red, "Attack" and B to another icon; both written in Steam's format and loaded back after a
session restart.
The pickers are panels in the session's window, not dialogs.
## Steam Link's menu and editor
- **Menu button (…)**: touch input Controller / Mouse / Controller + mouse; mouse as direct touch or
trackpad; trackpad speed. Like Steam Link these are per game, saved in the game's `touch_layout`
(`CVirtualControllerLayouts` fields 2-4), so they sync with the config. In Controller mode touches
outside the controls do nothing; in Mouse mode only the menu button is drawn and the screen is the
mouse. Also: vibrate on touch, fade when not touched, gyroscope (Steam Link's global options, kept
per device), the layout editor and DroidDeck's own menu.
- **Editor**: ◀ ▶ steps through every action set of the game's config (each saved to its own layout),
Add (the tray: bound controls not on screen, and the optional Paste button), More (colour and
opacity, copy a layout, paste it into another game, reset), W−/W+/H−/H+ and axis-wise pinch for a
control's width and height (ovals).
- **Paste** control: Ctrl+V into the session (the Android clipboard is shared with it).
Not done: Steam Link's magnifying glass / pinch zoom, record and playback of input, shake to fade, and
its custom tray drag-in animation. Gyro: the report now carries motion only while the client asks
(setting report 0x30) at Steam Link's scale (1000 °/s full scale); a `gyro_to_joystick` binding still
did not move a game's stick with injected rates, so gyro remains unconfirmed.
## DroidDeck's look
With feature parity reached, the overlay keeps Steam Link's controls (outlined, white, Steam's face
colours) but is DroidDeck's own: the guide button carries the split-D mark (artwork/droiddeck-mark.svg)
instead of Steam's logo, and the menu, tray and pickers use the app's palette (ui/Theme.kt: surfaces
#121417 / #1A1D22, hairlines #262A31, text #F2F4F7 / #9AA3AF, accent #1A9FFF), rounded corners and
switches rather than Steam Link's navy panels and blue gradient tiles.
**Shake to hide**: a toggle in the menu (Steam Link's shake_fade). Three jolts above 2.3 g within
about a second hide the controls (touches then reach the game as with the controls off); shaking
again brings them back.
+225
View File
@@ -0,0 +1,225 @@
# Stores: GOG, Epic Games and Amazon Games in the launcher
How the Stores section (`app/src/main/java/com/droiddeck/launcher/stores/`, `ui/Stores*.kt`) fits
the rest of the app, and the on-disk contract that makes a store game an ordinary added game.
## Where a store game lives
```
<Games storage>/Games/<Store>/<title>/
<game files>
.droiddeck-store.json the sidecar (below)
.droiddeck-launch.bat only when the game needs arguments or environment (Epic, Amazon)
.droiddeck-epic-code one-shot, written right before an Epic launch, read and deleted by the .bat
```
The default root is the app's internal storage - the runtime's tree, `/root/Games/Stores`, no bind
needed - whatever the session's Game storage setting says. When a card the app may write is in the
device (`GameStorage.options`), Install asks "Install to" (internal / the card, free space shown;
the last pick is only the dialog's default). A card's root is `<card app folder>/Games`; when the
card is the Steam library the library's bind (`/mnt/droiddeck-sd`) already covers it, otherwise
`SessionService` binds the root at `/mnt/droiddeck-stores/<volume uuid>`, so a shortcut's guest
path - and its appid - is the same from one session to the next. Every root is
scanned (`StoreInstallRoot.roots`): internal, every card, and the Steam library's `Games` folder for
installs an earlier build put there. `<Store>` is `GOG`, `Epic` or `Amazon`; `<title>` is the title
with unsafe characters dropped, at most 60 characters (`StoreInstallRoot.folderName`), chosen once;
a rerun (repair, update) lands on the folder whose sidecar carries the game's id, wherever it is.
An Epic install on a card keeps its in-flight chunks in `cacheDir/stores/epic/<id>/`: the
`chunkCacheDir` of both native calls (`EpicNative.run` fetches into it, `EpicNative.assemble`
writes the files from it and drops each chunk after its last use, then the folder), and of the
manager's own loops when the engine is not there; `""` keeps the cache beside the game, as an
internal install has it. The scratch folder is removed on cancel-with-delete and on uninstall.
The cache holds whole ~1 MiB chunk windows, shared with files this device does not install, so it
is often larger than the game (Metalstorm: 9.1 GB of chunks for 4.4 GB of files); the free-space
check, made after the delta pass, counts the missing chunks and the missing files on their own
volumes. A successful run removes the cache.
## The sidecar
```json
{
"version": 1,
"store": "epic", // gog | epic | amazon
"id": "Samorost3", // the store's own id: GOG product id, Epic app name, Amazon product id
"title": "Samorost 3",
"exe": "Samorost3.exe", // relative to the folder, forward slashes; what the icon is read from
"launcher": ".droiddeck-launch.bat",// optional; what the shortcut runs instead of exe
"args": ["-EpicPortal", "-epicusername=\"Name\"", "..."],
"env": {"FUEL_DIR": "C:\\ProgramData\\Amazon Games Services\\Legacy"},
"installVersion": "1.4.0",
"installedAt": 1759900000000,
"cover": "https://...", "hero": "https://...",
"extra": {"namespace": "...", "catalogItemId": "..."}
}
```
An install writes the sidecar at its start with `"state": "installing"` (store, id, title, no exe)
and rewrites it finished at its end (exe, launcher, no state field = installed). A folder under a
store root whose sidecar says `installing`, or that has no sidecar at all, is an unfinished
install: `AddedGames.scan` leaves it out (it is neither a game nor a Custom folder), and the Stores
card and page offer **Resume install**, which reuses that folder - and an Epic `.chunks` beside it -
instead of starting a fresh one (`StoreInstallRoot.existingFolder`). A finished install being
repaired keeps its finished sidecar. The launcher and the finished sidecar are written before the
art and the Steam registration; a failure writing them fails the download with its message.
`StoreGameSidecar.parse` refuses anything whose `exe` or `launcher` would point outside the folder.
Every store install is a Steam shortcut; an `addToSteam` field in a sidecar from an earlier build is
read past and ignored.
## Registration with Steam
`AddedGames.scan` walks the store folders as it walks the user's added folders, and
`AddedGames.scanGame` reads the sidecar: the exe (the folder's guess only when that file is gone),
the title as the shortcut's name, the store as the game's `source`. From there the path is the one
an added folder takes: `session/added-games.json` → `droiddeck-steam-shortcuts` at the client's
next start. `StoreInstalls.register` rewrites the listing at install time, so a client that restarts
inside the running session already has it, and asks a running client to add the shortcut live over
its DevTools port (`SteamLiveShortcuts`: `SteamClient.Apps.AddShortcut`, our tag, the compat tool).
The appid Steam derives (CRC32 of the quoted exe plus the name, high bit set) is the one the
listing carries, so the live add and the writer never disagree. Uninstall removes the folder and the
listing drops the entry; the live client is asked to remove it too.
`Library.SteamGame.source` is `steam`, `gog`, `epic`, `amazon` or `added`; the Games tab shows it as
a chip on every row and in the hero.
## Launch
A Steam shortcut names an exe and nothing more, and the listing carries no launch options, so a
game that needs arguments or environment gets `.droiddeck-launch.bat` (`StoreLaunch.launcherText`):
`cd` into the exe's folder, `set` each variable, start the exe with the arguments and wait. Proton's
`steam.exe` shim hands a `.bat` to Wine's `cmd`. For Epic the script also reads
`.droiddeck-epic-code` when present, deletes it, and passes
`-AUTH_LOGIN=unused -AUTH_PASSWORD=<code> -AUTH_TYPE=exchangecode` on the game's command line only;
the variable it read the code into is cleared on that same line, so nothing of it is left in the
game's environment. A launcher from an earlier build is rewritten before the next Epic launch.
The code is minted for every launch, wherever it starts. The Games tab and Stores call
`StoreLaunch.prepare` before they launch; the compat tool (`droiddeck-proton`,
`droiddeck-proton-wrap`) runs `droiddeck-store-launch` before Proton on every real launch, the Steam
client's Play button included. It finds the store launcher among Steam's arguments, reads the
sidecar beside it, and for an Epic game asks the app through `<session>/stores/req` and `resp`
(`StoreLaunchRequests` → `StoreLaunch.epicCode`), waiting up to 5 s; the app writes the code into
the game's folder itself. Each attempt logs `epic launch id=… code=yes|no reason=…`, never the code.
An Epic game's launch choices are the Epic card in the Games tab's launch settings - "Epic sign-in
(EOS)" (on) and "Launch offline" (off), stored in the sidecar's `epic` block so both launch paths
read the same thing - and "Resolve Epic sign-in", which opens Epic's account page behind its
sign-in in Android's browser.
A game's web links reach Android: `droiddeck-store-launch` sets the prefix's
`HKCU\Software\Wine\WineBrowser` `Browsers` to `/usr/local/bin/droiddeck-open-url`, which is also
`xdg-open` first on the game's PATH, and hands http(s) addresses to the app, which opens them in
Android's browser. EOS uses this when a sign-in needs a one-time step ("corrective action"): it
falls back to a browser, the user approves on the phone, and the game signs in. `BL_DEBUG_BROWSER=1`
in droiddeck-env adds `WINEDEBUG=+shell,+winebrowser`. Epic's EOS overlay is not provisioned (with
it games exited while loading); an `OverlayPath` an earlier build wrote is removed at launch. The
parked overlay work is on the branch `park/epic-eos-overlay`.
## Cloud saves
GOG and Epic games sync their saves with the store's cloud (`CloudSaves`, after Bannerlator's
managers): before a launch the cloud copy comes down, after the game exits what changed goes up.
`CloudPlan` decides per file against a baseline - each file's local MD5 and cloud MD5/time as of
this device's last sync:
- **No upload before a download has completed once on this device** (no baseline): a first launch
creates new profile files that must never replace the real saves in the cloud.
- **The first download lets the cloud win** where the two differ.
- **A file changed on both sides since the baseline is a conflict:** neither side is overwritten;
Manage saves shows "Cloud conflict" with Keep cloud / Keep local.
- Otherwise the side that changed wins; bytes that match move nothing.
Both sides are backed up before they are replaced: the local folder before a download writes into
it, the cloud copies before an upload replaces them, under
`files/stores/cloud-backups/<store>-<id>/local-*` and `cloud-*` (the last three of each).
A game launched before Proton has made its prefix (a first launch) gets its download deferred: the
request is answered at once (`result=deferred reason=no-prefix`) and the download runs as soon as
the prefix's user folder appears, within a minute. Every path logs
`cloud <store> <id> down|up result=ok|skipped|deferred|failed files= bytes= reason=`.
- **The folder:** GOG's public remote-config gives a location template per game (by its Galaxy client
id), e.g. `<?APPLICATION_DATA_LOCAL_LOW?>/Hyperstrange/ELDERBORN`; Epic's catalog gives
`CloudSaveFolder`, e.g. `{AppData}/Game/Saved/SaveGames`. `CloudSavePaths` expands it inside the
game's prefix (`compatdata/<shortcut appid>/pfx/drive_c/users/steamuser`) or its install folder,
case-insensitively, and refuses a path that leaves its boundary. A game whose store gives none
has no cloud saves.
- **The services:** GOG `cloudstorage.gog.com/v1/<user>/<client>` with a token issued to the game's
own client (the client secret is kept at install; the Galaxy token is the fallback); Epic's
savesync data storage with signed read and write links.
- **Which launches:** `droiddeck-store-launch` recognises a store game by the launcher .bat Steam runs
or, for a game without one (most GOG games), by its exe - the folders above it are searched for
the sidecar.
- **When:** every launch runs `droiddeck-store-launch`, which asks the app (`cloud-down`) and waits up
to 15 s; for a store game with cloud saves it returns 10, and the compat tool then waits for
Proton instead of exec'ing it and runs `droiddeck-store-launch --exited` after, which asks for
`cloud-up` without waiting. Each sync logs `cloud <store> <id> down|up files= bytes= result=`.
- **Uploads that do not depend on one hook:** the pre-launch step marks the game dirty in the app's
storage; the upload runs on the first of the compat tool's exit request (`trigger=exit`), the
session's end (`trigger=session-end`, after teardown, reading the prefix directly) or the app's
next start for a mark a killed app left (`trigger=recovery`, not while a session runs). The mark
goes only after an upload that went through or a final skip (off, no cloud saves, no baseline,
not installed, nothing local).
- **Per game:** a GOG or Epic game's hero button reads "Cloud saves" and opens its saves view: the
Cloud saves switch (on; the sidecar's `"cloud"`, read by both launch paths), the last sync,
Upload / Download and the conflict actions, or "No cloud saves".
## Downloads
`DownloadQueue` runs 1–3 jobs at a time (Setup / the Downloads page), each a store's whole install
(`DownloadJob.run`), with stages Manifest → Download → Verify → Install. Pause stops the job and
keeps the files; every store's install skips complete, verified files on the rerun, so resume is a
rerun. Cancel deletes the folder. `StoreDownloadService` holds a foreground notification while
anything runs. The native engine (`libdroiddeckstores.so`, `StoresNative`, `GogNative`, `EpicNative`,
`AmazonNative`; contract in `app/src/main/rust/stores/JNI.md`) is loaded on first use; without it
each manager runs its Java fetch loop.
## Settings
| Setting | Pref | Where |
|---|---|---|
| Show Stores in the rail | `SessionPrefs.gameStoresEnabled` (off) | Setup › Stores |
| Open a store on: Library · Store | `SessionPrefs.storesOpenTab` (library) | the chip row's cog, Setup › Stores |
| Download speed tier | `SessionPrefs.gameStoresSpeedTier` (fast) | the cog, Setup › Stores, Downloads |
| Downloads at a time | `SessionPrefs.gameStoresParallel` (1) | Downloads |
| Install to (last pick, dialog default only) | `SessionPrefs.storesInstallTarget` | the Install dialog |
Store log lines (the engines' included) go through `StoresState.logLine`, which redacts them
(`StoreLog.redactLine`) and writes them to logcat and to `filesDir/logs/stores/stores-<date>.log`
(`StoreLogFiles`: one file a day, seven days kept, ~2 MB each before it rolls to `.1`). Nothing
shows them in the app; the session's Share logs zip carries them under `stores/`.
Store URLs are logged through `StoreLog.redactUrl`, which drops the query string where the signed
tokens live.
## Security
- **Sign-ins:** `filesDir/stores/<store>/credentials.json` only, read and written through
`StoreAccounts` alone (`GogAuth`, `EpicCredentialStore`, `AmazonCredentialStore`, cloud saves
all call it). The file is an envelope `{"v":1,"alg":"AES/GCM","iv":...,"ct":...}` (base64):
AES-256-GCM (`CredentialCipher`) under a key generated in the AndroidKeyStore (alias
`droiddeck-store-credentials`; encrypt/decrypt, GCM, no padding, not exportable, no user
authentication so background downloads and launch-time exchange codes work with the screen off;
StrongBox where present, else the TEE). Written through a temp file and a rename, mode 600.
- **Earlier plain files:** sealed at app start (`StoreAccounts.encryptAll`, and on any read),
verified by opening the result, the plain file replaced; the log says
`stores: credentials encrypted <store>`. A plain `.tmp` left by an older build is deleted.
- **No Keystore** (some ROMs): the file stays plain, the log says
`stores: keystore unavailable, credentials stay plain (<exception class>)` once, and the next
start tries again.
- **A file that can never open** - it does not authenticate (`AEADBadTagException`: tampered, or
another key after data was cleared or a backup restored on another device), the key is
permanently invalidated or gone from the Keystore, or it is not an envelope: deleted, and the
store reads as signed out, so its sign-in card shows.
- **A failure that may pass** (`KeyStoreException`, `ProviderException`, any other
`InvalidKeyException`, an I/O error, StrongBox busy): the file is kept, the store stays signed in
(no sign-in card) and is marked unavailable (`StoreAccounts.isUnavailable`), a store action shows
`<Store> sign-in could not be read: try again.`, the log says
`stores: credentials unreadable this start (<exception class>)` once, and the next access tries
again.
- **The Linux session:** the app's files directory is bound into every session, so the guest can
see `credentials.json` - as the envelope only; the key never leaves the Keystore. Nothing in the
guest reads the files: `droiddeck-store-launch` asks the app over `<session>/stores/req|resp`
for an Epic exchange code, which the app writes beside the game's launcher; the launcher reads
it into a variable and deletes it before the game starts (single use, expires in minutes).
Steam's own client files are outside this.
+532
View File
@@ -7,6 +7,538 @@ the timeline, then lessons and backlog. Companion to the README (what the app *d
---
## 2026-10-09 - `feat/games-add-edit`: add games from the Games tab, edit them like Steam's Properties
- **Steam ⚙ settings:** the Games section is gone (it was a feature, not a setting). Games
folders added before keep listing their games.
- **+ beside "Games N":** a compact in-app picker (storage step, then the storage root; every
folder A-Z, unreadable ones greyed; `.exe` only; width fixed at opening; red X; B goes up).
Picking an exe adds the game (name from `GameIdentifier`, art, Custom chip, Steam shortcut via
the listing and the running client, Start in = exe folder) and selects it; an exe in a listed
game switches its target; the same exe again selects it; a path the session cannot see is
refused. Internal storage anywhere now maps to `/root/Storage`.
- **"Add all games in this folder":** each subfolder with its best exe (`GameExePicker`, depth
5, "?" when unsure), listed ones skipped, then a summary (added, already there, rows that open
the editor with back to the summary).
- **✎ editor** on a Custom game: Name, Target (ranked, "?", Other exe…), Start in, Launch
options, Artwork (Cover, Background, Logo, Icon with thumbnails and sources; chooser with the
game folder, Steam and SteamGridDB; Pick image…; Reset to automatic), Remove (two presses, files
kept). Every edit goes through the same shortcut on its stored appid (listing + live DevTools);
the writer keeps Steam-side edits and records them, and the app takes them over once.
- **Setup:** Artwork switch and SteamGridDB API key (user key sealed with the Keystore, wins over
`BuildConfig.SGDB_API_KEY` from the `SGDB_API_KEY` secret).
- Brought over from `feat/added-games-remove` (not merged): `GameExePicker`, `GameIdentifier` +
`PeVersionInfo`, the art and SteamGridDB work, the build secret, the + and the picker.
- Docs: `docs/development/added-games.md`. Tests: `AddedExesTest`, `AddedGameEditsTest`,
`AddedGamesCandidatesTest`, `AddedGameArtLookupTest`, `GameIdentifierTest`, `PickListingTest`,
`AddedGamesRemoveTest`, `test_steam_shortcuts.py`. Not yet on a device.
## 2026-10-09 - `feat/store-credentials-keystore`: store sign-ins sealed with the Android Keystore
- **What:** `filesDir/stores/<store>/credentials.json` (GOG, Epic, Amazon: tokens, ids, names,
expiry) is now an AES-256-GCM envelope (`{"v":1,"alg":"AES/GCM","iv","ct"}`) under a
non-exportable AndroidKeyStore key (StrongBox if present, else TEE; no user authentication).
`StoreAccounts` is the one layer; `CredentialCipher` holds the envelope and the key.
- **Upgrade:** a plain file is sealed at the first start (verified, then replaced); users stay
signed in. Log: `stores: credentials encrypted <store>`.
- **Fallbacks:** no Keystore - stays plain, logged once, retried next start. A file that can never
open (bad tag, key invalidated or missing, not an envelope) - deleted, signed out (sign-in card).
Any other Keystore or I/O failure - file kept, store stays signed in but unavailable (actions show
`<Store> sign-in could not be read: try again.`), logged once, retried on the next access. Never
a crash.
- **Session:** the guest sees the envelope only; it never read the files (the Epic code comes over
the request channel, written beside the launcher and deleted by it).
- **Tests:** `StoreAccountsCipherTest` (round trip, sealed on disk, migration of all three stores,
tampered file, lost key, key missing, garbage, no-Keystore fallback then sealed next start,
transient Keystore / I/O failures keep the file and a later read succeeds, sign-out). Not yet
on a device.
## 2026-10-08 - `feat/private-logs`: every log in app-private storage, shared as one scrubbed zip
- **Where logs live:** `files/logs/` (`LinuxRuntime.logDir`), nothing under `Download/DroidDeck`
any more. Session folders (`<day>-NN-<what>/`), `tools/` (GuestCommand, Flatpak, Windows
component installers) and `stores/` (the stores' engine log, one file a day) all sit there. The
files directory is bound into every session at the same path, so the session script, gamescope
and the guest tools write there as before. Thirty sessions kept; the Logs switch off still means
a cache folder deleted at session end. Game save backups stay public in `Download/DroidDeck/Saves`.
- **Moving the old ones:** on the first start of this build, session folders, `tools/` and loose
`*.log` files move from `Download/DroidDeck/` into `files/logs/` (rename, else copy and delete;
an item that fails stays). A marker records the pass; `Saves/` and anything else there is never
touched, and the app does not read `Download/DroidDeck/` again.
- **Share logs:** one zip in `cache/share/`, made on demand: the newest session folder (or the one
the session screen shares), the last seven days of `stores/` and `tools/`. Every text file goes
through `LogRedactor.redactForShare` on the way in - the existing rules (Steam tokens, JWTs,
SteamIDs, account names, emails, own addresses, MACs, serials) plus URLs without query, fragment
or userinfo and with token-bearing path segments blanked (GOG secure links), `__token__`,
`f_token`, `hdnts`, OAuth `code=`, and Authorization / Cookie headers - so a file written before a
rule existed is clean in the zip. The zip is deleted at the next share or app start.
`SessionLogShareTest` covers it. Nothing was relaxed: the per-session scrub, `scrubOlder` and
every existing rule stay as they were.
- **File manager:** the Session logs shortcut opens `files/logs` (the app reads its own storage).
- **On main after Stores (#476) and the KDE Plasma desktop (#473):** the stores' log is already
`files/logs/stores/stores-<date>.log` and the zip carries its last seven days under `stores/`. One
set of rules scrubs both the stores' log and the zip (`SecretScrub`): `StoreLog.redactLine` keeps
URLs to their host and first plain segment, the zip pass keeps paths with token segments blanked,
both blank token values and Authorization / Cookie headers; the two test suites pass on it. The
Plasma desktop writes nothing outside the session folder (its output is the session's
`desktop.log`), so there was nothing new to move.
- **Privacy scan fixes:** the Steam login account (an email, 374 times) was still in older
folders' copied `steam/webhelper_js.txt` (`SteamUI: INFO: Login: OnLoginStateChange <account>`):
those folders carried a scrub marker from before the account rules, and the marker never
expired. The marker is now named after the redactor's rules version (`.scrubbed-r3`), so every
folder scrubbed under older rules goes through again at app start, steam/ and every subfolder
included; folders moved out of `Download/DroidDeck` lose every old marker
(`SessionArtifacts.unmarkMoved`), so the same pass takes them whatever those markers said. New rules: `OnLoginStateChange <anything>`, and
`AccountName` / `account_name` / `username` / `login` fields (`login` only as `login=`, a quoted
key or a VDF pair, so the "Login:" label stays). The `code=` rule no longer touches Proton's
exception codes (`code=c0000005`, `406d1388`, `80000003`): a bare `code=` is blanked only right
after `?`/`&` or on a line with OAuth keys (`client_id`, `redirect_uri`, `state`, tokens), and
never when it is 8 hex digits; exchange / authorization codes are always blanked. Tests:
`LogRedactorTest` (the login line with an email and with a plain name), `SecretScrubTest`,
`SessionLogShareZipTest` (older and moved folders scrubbed on disk).
- **Device check (31 migrated folders):** only 4 carried `.scrubbed-r3` a minute in. Nothing was
skipped - the pass was still running: one folder holds ~30 MB of Steam logs, ~30 s through the
redactor, one folder after another (about 15 minutes for 31). The start pass now scrubs a few
folders at a time (half the cores, at most 4, background priority), old markers go whether or
not a folder's pass succeeds, a folder the process does not finish is taken up at the next start,
and it logs one line: `logs: scrubbed N folders under r3`. Test: nine migrated folders carrying
`.scrubbed-2`, `.scrubbed-1` or a stale `.scrubbed-r3` all end up scrubbed under r3 after one
migration + start pass.
- **LAN addresses in the zip:** private IPv4 addresses (10/8, 172.16/12, 192.168/16, 169.254/16;
e.g. the router in `LinuxNetworkLink: resolver: ...`) become `<lan-address>` in the zip pass;
public server addresses and dotted version numbers stay (`LogRedactorTest`).
## 2026-10-08 - `feat/stores`: GOG, Epic Games and Amazon Games in the launcher (in progress)
A new **Stores** section - the three storefronts' libraries and public catalogs, one download
queue for them, and every install registered in the Steam client exactly like an added folder.
Ported from Bannerlator's store clients (auth, API, library sync, download managers); its
Activities and XML are not ported, the UI is Compose, after the approved preview. The native
download engine is the Rust side's work (`libdroiddeckstores.so`, loaded lazily; the app runs
without it and Setup says "Stores engine not built").
- **Where it lives.** Rail item `stores` under Games, gated by Setup › Stores › "Show Stores in
the rail" (`SessionPrefs.gameStoresEnabled`, off by default); a count badge while anything is
downloading. The page is full width: four chips (GOG · Epic · Amazon · Downloads, a signed-in
dot per store) and a cog at the row's end whose popup holds the section's own settings - which
tab a store opens on (`storesOpenTab`, Library by default; applied on chip tap, never while the
user is switching tabs by hand) and the speed tier (`gameStoresSpeedTier`, Balanced / Fast /
Max = 16 / 32 / 96 requests in flight). Setup repeats the rows under the gate. A signed-out store
shows its sign-in card first. Every install is added to Steam - the user's call: "Add to Steam
shouldn't be optional, automatic" - so the switch an earlier build had (`gameStoresAddToSteam`,
the sidecar's `addToSteam`, the page's "Add to Steam" button) is gone; an older sidecar's field
is read past and ignored, and the game page shows a passive "In Steam" chip. The Games hero's
eyebrow for a never-played store game reads "Games storage" (the chip names the store), and
"Custom game" for a hand-added folder; Steam titles keep their library label.
- **A store game is an added game.** The install lands at `<Games storage>/Games/<Store>/<title>`
(the SD library's folder when one is chosen, else the runtime's own `/root/Games/Stores`) with a
`.droiddeck-store.json` sidecar (store, id, title, exe, launcher, args, env, version,
addToSteam, art). `AddedGames.scan` now walks those folders too and `scanGame` reads the sidecar
for the exe and the name, so the game goes down the existing path: `session/added-games.json`
→ `droiddeck-steam-shortcuts` at the client's next start. The listing is rewritten at install
time, and with a client running the shortcut is added live over the client's DevTools port
(`SteamClient.Apps.AddShortcut` + our tag + the compat tool; `SteamLiveShortcuts`), best-effort.
Uninstall removes the folder, the sidecar and the shortcut.
- **Launch.** A shortcut can only name an exe and the listing carries no launch options, so a game
that needs arguments or environment gets a `.droiddeck-launch.bat` beside it (Proton's steam.exe
shim hands it to Wine's cmd): Epic's identity arguments, Amazon's FuelPump variables. Epic's
per-launch exchange code is minted by the app right before a launch into `.droiddeck-epic-code`,
which the script reads once and deletes; with no code the game starts in its offline identity
mode. The EOS overlay is never provisioned.
- **Games tab badges.** `Library.SteamGame.source` (steam / gog / epic / amazon / added, from the
sidecar) with a coloured chip on every row and in the hero eyebrow; `LibraryCache` keeps it.
- **Downloads.** `DownloadQueue` runs 1-3 at a time, stages Manifest → Download → Verify →
Install, pause = stop and keep the files (every engine skips verified files on the rerun),
cancel deletes; `StoreDownloadService` keeps the process alive meanwhile; the page shows speed,
ETA, the tier, downloads-at-a-time and the engine log.
- Tests: `StoreGameSidecarTest`, `AddedGamesStoreScanTest` (JVM), `tools/tests/test_store_shortcuts.py`
(the writer with a launcher .bat as Exe, the appid the app computes, removal).
- Files: `stores/*` (Store, StoreGameSidecar, StoreInstallRoot, StoreInstalls, StoreLaunch,
StoreAccounts, StoresState, StoresNative, SteamLiveShortcuts, download/*), `ui/StoresPage.kt`,
`ui/StoresDetail.kt`, `ui/StoresDownloads.kt`, `ui/StoreChips.kt`, `ui/StoresWidgets.kt`;
`frontend/AddedGames.kt`, `frontend/Library.kt`, `frontend/LibraryCache.kt`,
`ui/FrontEndRail.kt`, `ui/FrontEndContent.kt`, `ui/FrontEndSetup.kt`, `ui/FrontEndGames.kt`,
`ui/FrontEndScreen.kt`, `MainActivity.kt`, `session/SessionPrefs.kt`, `AndroidManifest.xml`
(the download service), `res/values/strings.xml`.
- **The three stores** (`stores/gog`, `stores/epic`, `stores/amazon`), ported from Bannerlator's
clients with their storage replaced: GOG's OAuth page (Galaxy identity, a browser identity for
the social-login hop), library from `embed.gog.com` + `api.gog.com`, shelves from
`catalog.gog.com`, gen2 chunks / gen1 ranges / plain installer; Epic's web login (the code off
the redirect's JSON page), library service + catalog, the store's GraphQL and the free-games
feed, ChunksV4 manifests with install tags and a delta pass, the manifest's launch exe; Amazon's
PKCE device sign-in, entitlements, `manifest.proto` (the app's xz library), SHA-256 per file,
`fuel.json` / exe scoring, FuelPump variables; Amazon has no public catalog, so its Store tab is
cut from the account's own games. Each manager hands the byte-fetch loop to the native engine
when `libdroiddeckstores.so` is there (`GogNative` / `EpicNative` / `AmazonNative`, JNI.md's
names and signatures) and runs its Java pool otherwise.
- Left out on purpose: GOG DLC installs and GOG redistributable installs (Steam seeds the shared
redistributables in the prefix as for any shortcut), Epic's Denuvo ownership token and overlay,
Amazon's SDK DLL deployment into the prefix (the prefix does not exist before the first launch),
cloud saves, and the stores' social tabs - none of them in the preview.
- **Card art (device feedback on `61a9a48`, GOG › Library washed out to white):** the GOG library
had drawn the product's `images.background` - the store page's fade-out backdrop, white once its
alpha is gone. The library now takes `api.gog.com/v2/games/<id>` `_links.galaxyBackgroundImage`
(the Galaxy client's dark 16:9 library art) and `boxArtImage` (the vertical cover), cached with
the sync (cache key bumped so old caches re-fetch); the catalog's `productId` filter was tried
and ignored by the service, so it is one call per owned game. Epic cards prefer `DieselGameBox` /
`DieselGameBoxTall` over the offer images; Amazon prefers `backgroundUrl2` and never the logo.
Cards draw over a dark surface with a fade into the card at the foot. On install `StoreArt`
places `cover.jpg`, `hero.jpg` and `header.jpg` in the game folder, re-encoded as opaque JPEGs
over a dark ground, under the names `AddedGameArt` looks for - so the Games tab and the client's
grid (through the listing) get real art for store games.
- **Device feedback on `9f5a2f3` (GOG › DOOM I Enhanced page):** (1) the pad lost focus when a
card opened its page (the card left composition; the next press landed on the rail). The page
now follows the Flathub store's pattern: a focus move is recorded on each change and
`focusWithinFrames` lands it - the game page's main action (or its back link), the card the page
was opened from on the way back, the first card after a tab or chip change (`firstTile`); the
page is a `focusGroup`, so Left is the way to the rail. (2) GOG's account endpoints return
template keys (`product_description_2015545325<br>product_feature_…`) for some products; the
v2 record has the same keys for them. `cleanStoreText` drops those keys, strips tags, decodes
entities; the library tries the product's lead, then v2 `overview`, then v2 `description`, and
shows nothing when all are templates. Epic's and Amazon's text goes through the same cleaner.
- **Speed shown = install rate.** Device evidence (Epic › Metalstorm, 1.68 GB on Max to the SD
card): the engine's windows burst at 0.4–20 MB/s with 0–3 of 20 requests in flight while the card
writes at 26 MB/s - the fetchers wait on the write side, so the engine's `speedBps` jumped while
the bar advanced at the write rate. `DownloadQueue` now measures the shown speed itself from the
byte deltas (an exponential average over 3 s, sampled at most every 250 ms) and derives the ETA
from it, for all three stores; the engine's own figure stays in its log lines, and the detail
line under the bar has it stripped. The tier and downloads-at-a-time controls sit on one compact
row, on the Downloads page and in the cog's popup.
- **Install location (user decision):** the default is the app's internal storage for all three
stores, whatever the session's Game storage says. With a card in the device, Install asks
"Install to" first (internal / the card, free space per target, pad-focusable, last pick as the
default only). A card that is not the Steam library gets a bind of its own in the session
(`/mnt/droiddeck-stores/<volume uuid>`; the library's own bind covers a library card, so installs
already registered there keep their appid); every root is scanned and uninstall works for
either. The Downloads
row shows where a game is going; the game page names the
place. Epic installs on a card keep their in-flight chunks in the app's cache: the engine's
`chunkCacheDir` (fetch and the new `nativeAssemble`, which drops each chunk after its last use)
and the manager's own loops read the same path; internal installs pass `""` as before. Cleaned on
cancel-with-delete and uninstall.
- **Half-installed Epic game shown as Custom (device, Metalstorm on the SD card).** The folder had
2.85 of 4.4 GB of files, a 0-byte file where the assembly stopped (19:15:10, four minutes after it
began), 9.1 GB of `.chunks`, and no sidecar. The run stopped inside the assembly loop - before the
`.chunks` removal and the sidecar, both of which only ran at the very end; the events log does
not reach back far enough to say whether the process died or the loop threw. Either way three
things made it silent: the sidecar was only written last, the queue lives in memory (a process
death drops the row), and `AddedGames.scan` listed any sidecar-less folder under a store root as
a Custom game. Now: the sidecar is written at the start in state `installing` and finished at the
end; unfinished folders (installing, or no sidecar) are never scanned as games; the Stores card
reads **Resume install**, which reuses the folder and its `.chunks`; launcher/sidecar write
failures fail the download, art and Steam registration are best-effort. The 9.1 GB cache is
whole 1 MiB chunk windows shared with files outside this device's install tags - the free-space
check now counts cache and files; a successful run removes the cache (Kotlin loop and
`nativeAssemble` both).
- **The cog popup is capped at 440 dp**, like the Install dialog.
- **Store cards are art + one line** (maintainer feedback): no source chip (the tab says the
store), no "In library" chip, no action button. The title sits left; right-aligned is a check
when installed, Resume, the download percentage, the install size, or Free / price / discount.
A thin bar over the art while downloading. Install, Resume, Uninstall, Get and Buy live on the
game page; A on a card opens it.
- **No log panel:** the Downloads page's engine log is gone. Store lines go to logcat and to
app-private daily files (`filesDir/logs/stores/stores-<date>.log`, seven days, ~2 MB rolling to
`.1`), pruned as the app starts; the session's Share logs zip includes them under `stores/`.
- **Store log lines are redacted at the one choke point** (`StoresState.logLine`, which the engines'
lines reach too): every URL is cut to scheme, host and a plain first path segment (a GOG secure
link's token sits in the path, so it goes), no query, fragment or userinfo; token-like values
(`token`, `__token__`, `f_token`, `hdnts`, access/refresh/id tokens, `code=`) and Authorization /
Cookie headers are blanked outside URLs too. `StoreLogTest` covers a GOG secure link and an Epic
Akamai URL. The engine's own logcat lines (tag `EpicNative` etc.) are written on the native side.
- **GOG downloads use every CDN host:** the secure link lists several hosts; only the first was
taken (`used=1/1 servers`). All are parsed now and kept as one set, refreshed together on
expiry; the Java pool takes them in turn. The progress bars glide to each new value over 250 ms. With the engine's `0849a7c` the
native start takes the whole set (`cdnBases`; the engine spreads its window across the hosts) and
its `onBytes` - every 250 ms, including files still in flight - drives the bar and the speed, so a
large file no longer moves the bar in one jump.
- **Cloud saves device-proven (AYANEO Pocket FIT, `6a175f1`, ELDERBORN on GOG):** the launch logged
`cloud gog 1732383191 down result=ok files=5 bytes=237499 reason=downloaded` (template found) and
the in-game slot shows the cloud save (Catacombs: Tutorial part 1, 00:08:40).
- **Store cards a quarter smaller:** 112 dp least width (was 150) for shelf cards and grid cells; the
grid fits as many columns as the width allows and shares the rest, so a density setting changes
the column count; titles stay at 11 sp, art 16:9. Downloads rows unchanged.
- **Cache first, refreshed in the background:** a store's library shows from its saved copy at once
and is refreshed at most every six hours (or from the account row's Refresh), the result merged
so unchanged cards keep their objects - only changed cards recompose, the grid's scroll and the
pad's focus stay. Shelves saved on an earlier run count as fresh for three hours. Sizes are kept
per game and version in `filesDir/stores/<store>/sizes.json` (format-versioned) and looked up
again only for a new version. An installed card shows its size on disk with a small green check
after it.
- **Every owned card shows its size** at the right of its title strip, in the title's type: GOG's from
its catalog; Epic's (build manifest, the files this device installs) and Amazon's (download
manifest) looked up once a card is on screen or close, three at a time in the background, kept in
the store's prefs (`size_<id>`). Nothing shows until it is known; a marker (installed, Resume, a
download's percent) keeps the slot.
- **Two tabs, Store and Library** (the All count mixed owned games with whatever shelves had loaded:
GOG Library 33 / All 120): Library's dropdown filters All (every owned game, the default, the
tab's count) or Installed, and the tab reads the filter ("Library (33)", "Installed (1)"); the old
All view is gone. Amazon has Library alone. Search follows the filter; the shoulders cycle Store
and Library. The dropdown opens under the Library tab, left edges aligned, as wide as its
entries (at least the tab, at most 260 dp) - `AnchoredMenu(compact = true)`.
- **The Stores chip row paints nothing** (maintainer: a black box behind the chips): it sits over the
page's own background; the content scrolling under it is clipped at its edge and faded there by
the content's alpha once scrolled, never by a colour.
- **Pre-PR device checks pass (AYANEO Pocket FIT):** GOG install, launch and cloud saves down and up
(the session-end upload included); Epic with EOS sign-in; Amazon (Dread Templar); an SD-card install
(DOOM I Enhanced) launched from `/mnt/droiddeck-sd`.
- **Downloads page, icons and one Clear** (maintainer): the row actions are round icon buttons -
pause, resume, play, retry, and a cancel that asks with a red delete and an undo - their labels as
descriptions. Downloads under way sit on top; finished ones below a line whose X clears them all
(rows only; a failed download's kept files stay for its game page's Clear), installed ones as a
compact row with Play.
- **Saves menu without explanations:** Import / Export rows (Steam, Custom, GOG and Epic alike) lose
their descriptive subtitles; only live values remain (last sync, "…", conflict count, the save
folder and its size). The three strings are gone from every locale.
- **One place for a store game's saves:** a GOG or Epic game's hero button reads "Cloud saves" and
opens its saves view, which now holds the Cloud saves switch, the sync status, Upload / Download
and the conflict actions ("No cloud saves" when the store keeps none). The switch is gone from the
cards; GOG has no card left, Epic's keeps sign-in, offline and Resolve Epic sign-in. Steam and
Custom games keep "Manage saves". The view is laid out in full from the first frame - the switch (focused),
Upload and Download with "…" until the cloud check is back - and only subtitles change after; a
conflict turns the two actions into Keep local / Keep cloud in place.
- **Background downloads:** while a download runs the service holds a Wi-Fi lock and a partial wake
lock (timed, renewed with the progress, released when nothing runs). The notification shows a
real progress bar and "<game> · 42% · 1.2 GB/2.5 GB · 12.3 MB/s · 3 min" (the stage while
installing), with Pause / Resume and a two-step Cancel (Delete / Keep, ten seconds); a paused
download leaves a notice to resume from; "<game> installed" opens it in Games, "<game> download
failed" opens Downloads. Notifications are asked for once on Android 13+. The Android 15 dataSync
time limit (and its `onTimeout`) applies only to apps targeting 35+: this app targets 28 and
compiles against 34, so there is nothing to handle yet.
- **Cloud uploads do not depend on the exit hook:** a dirty mark per game launch; uploaded on the
first of exit request, session end, or the next app start (`trigger=exit|session-end|recovery`).
- **Cloud saves, device round 1 (ELDERBORN, `b323a0b`): nothing ran** - a GOG game without arguments
gets no launcher .bat, Steam runs its exe, and `droiddeck-store-launch` only recognised the .bat.
It now recognises the exe too (searching the folders above it for the sidecar), and every path
logs a result line. A first launch has no prefix yet: the download is deferred until Proton makes
it, without holding the launch. Uploads are now safe: none before a download has set this
device's baseline, a file changed on both sides is a conflict left for Keep cloud / Keep local,
and the cloud copy is backed up before an upload replaces it (`CloudPlan`, tests for each rule).
- **GOG and Epic cloud saves** (ported from Bannerlator's managers, device-proven there in August):
down before every launch where the cloud copy is newer (the compat tool waits up to 15 s), up
after the game exits (the compat tool waits for Proton for such a game, then asks without
waiting), newest wins per file with an MD5 check, a backup of what a download overwrites (last
three). The save folder comes from GOG's remote-config template or Epic's CloudSaveFolder,
expanded inside the game's prefix (`CloudSavePaths`, Bannerlator's cases as tests). A "Cloud
saves" switch on the GOG / Epic card, and cloud rows in Manage saves (last sync, Upload,
Download, "No cloud saves"). Not yet device-tested.
- **Epic sign-in device-proven without the overlay (AYANEO Pocket FIT, `bf81104`, Metalstorm):** EOS's
corrective-action browser flow → `droiddeck xdg-open: https://www.epicgames.com` → Chrome
`epicgames.com/id/authorize?user_code=…` → approved → `[eos] got logged in`, product user id
created, the game in its hangar at 92 fps. The EOS overlay crashed the game on every overlay-on
launch, so it is removed (user decision): no overlay switch, no download, no `OverlayPath`; a
launch removes a pointer an earlier build wrote, and the app deletes an earlier 656 MB download
once. The work is parked on `park/epic-eos-overlay` (at `bf81104`). Kept: the browser hand-off,
the Epic card (sign-in, offline, Resolve Epic sign-in) and `BL_DEBUG_BROWSER`.
- **A game launched from the Games tab with no session running sat at "Launching"** (device,
2026-10-09-04-steam, and 2026-10-08-05 before it). The session put `steam://rungameid/<id>` on
the client's command line; the client took it seconds before its interface was up (focus went to
769 at 04:29:07, the launch at 04:29:09) and its launch stopped at `LaunchApp waiting for user
response to ShowInterstitials` with nothing to answer - the next launch from inside Steam went
straight through. Not store-specific: the 2026-10-08 cold launch of another shortcut stopped the
same way. `droiddeck-session` now holds such a URL back and hands it over through the same
`steam-game` request an in-session launch uses, once gamescope's focused app is the interface
(769) and four seconds have passed, or after two minutes regardless. The `rc=139` at the end of
both sessions is the client crashing in its own shutdown, after "Shutdown", unrelated to the
launch. The shortcuts writer keeps a compat tool the user chose (`plan_mapping` skips an entry
that is not one it set itself), and the live add sets one only for a new shortcut.
- **Why EOS's browser flow never reached Android:** the hand-off script was never in the APK. The
build copies only `usr/local/bin/droiddeck-*`, `steam-compatibility` and `usr/bin/**` of the overlay
into the assets, so `usr/local/lib/droiddeck/browser/xdg-open` was skipped, the session staged
nothing, the wrapper did not put it on the PATH, and Wine's winebrowser ran the runtime's own
`/usr/bin/xdg-open`, which has no browser to open in a Steam session. GE-Proton 11-7's winebrowser
(Metalstorm's tool) is Wine's own - registry `Browsers` list, then `xdg-open` by name - with no
steam://openurl route. The script is now `usr/local/bin/droiddeck-open-url`: named as Wine's
browser in the prefix (`"Browsers"="/usr/local/bin/droiddeck-open-url,xdg-open"`, an absolute path
that does not depend on Wine's PATH), linked as `xdg-open` first on the game's PATH, and reading
the session channel from `/tmp/droiddeck-browser/launch-dir` when Wine does not pass
`BL_LAUNCH_DIR` on. Whether EOS calls ShellExecute at all in its browser flow (rather than handing
a verification URI and code to the game to show) is what the next run's `droiddeck xdg-open:` line,
or `BL_DEBUG_BROWSER=1` in droiddeck-env (`WINEDEBUG=+shell,+winebrowser`), will show.
- **Resolve Epic sign-in** (the Epic card): opens Epic's account page behind its sign-in in Android's
browser, where a pending corrective action (privacy policy, EULA) is presented.
- **Epic overlay off by default** (device A/B, Metalstorm: overlay pointer set → exits while
loading, twice; off → signs in to its Starform account and runs at 118 fps). `EpicOptions.overlay`
defaults to false; the sidecar's `epic` block carries `"v": 2`, and an older block (the old default
wrote `"overlay": true` unasked) reads as off - in the app and in `droiddeck-store-launch` alike.
The 656 MB overlay is fetched only for a game that turns it on (the card's switch, or a launch of
such a game), no longer after every library sync.
- **The card's switches are saved where both launch paths read them:** each toggle reads the
sidecar fresh from disk, writes it and reads it back (`StoreGameSidecar.updateEpic`), and the card
shows what was read back; the app logs `epic options <id> eos= offline= overlay=`.
- **Registry lines that a running wineserver would drop:** `droiddeck-store-launch` waits up to 8 s
for a wineserver still holding the prefix to exit before appending to `user.reg` (it rewrites the
file from memory when it exits, which is how `OverlayPath` vanished), reads the value back, and
logs `overlay-set`, `overlay-off`, `overlay-not-written` or `overlay-still-set`, plus
`server-running` when one never left. The helper's docstring is raw (no SyntaxWarning).
- **Browser hand-off diagnostics:** the game-PATH `xdg-open` logs every call as `scheme://host`
only and accepts `steam://openurl/<address>`. On the device it was never called while EOS waited
on its browser flow, so how EOS opens the browser under this Proton is still to be seen in the
next log.
- **The exchange code no longer reaches the game's environment** (device: Metalstorm's Player.log
dumped `DD_AUTH: … -AUTH_PASSWORD=<code>`). The launcher read the code into a variable the game
inherited. It now clears the variable on the same line that starts the game - cmd has expanded it
there already - so the code is on the command line only; the variable has a plain name. An old
launcher is rewritten before the next Epic launch (`StoreLaunch.refreshLauncher`, from both the
app and the Steam-launch request).
- **A store game page shows no description that is only its title again** (Metalstorm's).
- **Epic launch card** (Games tab › Launch settings, Epic games only): "Epic sign-in (EOS)" on,
"Launch offline" off, "Epic overlay" on, stored in the game's sidecar (`"epic": {"eos", "offline",
"overlay"}`, kept across updates) so both launch paths honour them alike - the app's
`StoreLaunch.epicCode` and `droiddeck-store-launch` for a launch from the Steam client: no code
when sign-in is off or offline, the overlay pointer written or removed per the switch. The card
reads e.g. "EOS · Overlay". Bannerlator's forced ownership token (`-epicovt`) is not ported, so
there is no switch for it.
- **EOS overlay** (device: Metalstorm's EOS grant answered `corrective_action_required`, the overlay
was not configured, and EOS fell back to a browser flow that never finished). Epic's own overlay
component ("EpicOnlineServicesOverlay", the mechanism from Legendary's `lfs/eos.py`, credits in
`EpicOverlay.kt`) is downloaded once, with the Epic account's token, to
`/root/.local/share/droiddeck/epic-overlay` in the runtime - after an Epic library sync, or at the
first launch that finds it missing. `droiddeck-store-launch` then writes the one pointer,
`HKCU\Software\Epic Games\EOS` `OverlayPath` = that folder through Z:, into the game's prefix
(`STEAM_COMPAT_DATA_PATH/pfx/user.reg`, appended as DirectAudio's key is; a prefix Proton has not
created yet gets it on the next launch). Logged as `epic overlay installed=<build> prefix=<appid>`.
A game's web links now open on Android: Wine's browser is set to xdg-open, and on a game's PATH
`droiddeck-open-url` hands http(s) addresses to the app, which opens them
with Android's browser - so a device-code sign-in can be finished on the phone.
- **Epic sign-in from Steam's own Play button (device, Metalstorm "Guest Account"):** the game was
started from the Steam client, so the app never minted its exchange code - the code was only
written when a launch began in the app. Now the compat tool (`droiddeck-proton` and
`droiddeck-proton-wrap`, `steam-compatibility`) runs `droiddeck-store-launch` on every real launch:
it recognises the store launcher among Steam's arguments, and for an Epic game asks the app
through `<session>/stores/req|resp` and waits up to 5 s; the app (`StoreLaunchRequests` →
`StoreLaunch.epicCode`) refreshes the token, mints the code and writes it into the game's own
folder - the code never crosses the channel or the log. No answer: the game starts with its
offline identity. A code file older than five minutes is dropped first. Every attempt logs
`epic launch id=<app> code=yes|no reason=<ok|signed-out|sign-in-expired|exchange-failed|timeout|…>`;
a sign-in that ran out dims the Epic chip and shows the sign-in card. The Games tab and Stores
still prepare a code before they launch; the compat tool's request is the one every path shares.
- **Amazon has Installed and Library only:** with no public catalog its Store tab repeated the
library (Trending = Your library) and All equalled Library. The open-on Store choice falls back to
Library for Amazon. Amazon's library API carries no install size, so a size shows only once a
game has been installed (the manifest gives it then); no placeholder otherwise.
- **Shelves are titles only** (no "Just landed" / "On sale this week" lines); the chip row sits on
the page's own ground with room under it, and what scrolls passes beneath it clipped, with a short
fade where it meets the row.
- **Show mature content** (Setup › Stores and the cog; off by default): the storefront's shelves
and search leave out titles the store itself rates or tags as adult; Library, Installed and owned
games always show, and a title without rating data stays. GOG: `ratings[].ageRating` 17+ (ESRB M
17, PEGI / USK / GOG 18) or the tags `mature`, `nsfw`, `sexual-content`, `nudity` - the catalog
API has no server-side filter for either, so it is client-side. Epic: its public store GraphQL
carries no age rating on an offer (no age-gating or rating field on CatalogOffer or StoreConfig;
introspection is off), so only an adult content tag would mark one, and none of the probed
titles have one - Epic's storefront is effectively unfiltered. Amazon's Store tab is the user's
own games.
- **UI slow while downloading (device):** engines report per chunk or file, and each report
published a new queue that the whole front end read (the rail badge was computed from it in the
root composition). Now progress-only changes reach the UI at most four times a second (stage and
state changes at once), each row and card reads only its own entry, the list replaces itself only
when rows come, go or change state, the badge count changes only when it changes, and the
notification redraws at most once a second. Download threads run at background priority (the
queue's runner and every Java pool), the tier leaves two cores free (`processWorkers` capped at
cores - 2, at least 2), and the stores log is written in half-second batches. The native engine's
own threads need the same priority on its side.
- **Installed tab empty under "Installed (2)" (device):** the count came from the installs on disk,
the grid from the library filtered by id. Both now come from `installedCards`: each install joined
to its library item by id (or title), else a card from the sidecar's title and art.
- **GOG rows (device, DOOM + DOOM II):** bytes read "0 B" instead of blank; GOG and Amazon report
their size on disk from the manifest; their Install stage counts its finishing steps (record and
launcher, art, Steam) instead of sitting empty - GOG writes files in place while downloading, so
there is no file move to count. A stage a store skips reads complete once a later one starts.
The tier's window does reach GOG's engine (Max = 96 as its ceiling); the plan line now says so
(`gog: plan … window=96 … tier=max`). The per-host spread is the engine's and was not changed.
- **Stages named for what they do; both sizes; Cancel deletes.** Epic's check of the files already
there is part of Manifest ("Checking 120/515"), never a 100% Verify before anything is fetched.
Install has its own write rate and ETA from the bytes the assembler writes, and files n/N. The
row shows the download (compressed) as "1.6 GB / 2.5 GB" and the size on disk beside the
location; Epic remembers the disk size for the card and page. Cancel asks twice ("Delete
download?") and removes everything the install wrote - folder, sidecar, `.chunks`, scratch,
`.gog_chunks` - except a finished install being repaired, which keeps itself; the row says
Cancelled for three seconds, then goes, and the game reads Install. Pause keeps everything. A
failed row reads "Failed · 2.1 GB kept" (the reason is in the log) with Resume and Clear (Clear
deletes like Cancel); the game page offers Resume install and Clear for an unfinished install.
Library sync is a thin bar and "25/55", no sentence.
- **Per-stage progress** (device: Epic DOOMBLADE, 13 GB, ~3 min of assembly with a still bar). The
entry carries the active stage's own count (amount + files) and which stages are passed; the
Downloads row draws one segment per stage (Manifest, Download, Verify, Install), and its line
reads e.g. "Installing 42% · 120/515 files" (speed and ETA only during Download). Fed by Epic's
verify pass, its native and fallback assembly, and GOG's chunk-cache removal; Amazon writes while
it downloads and has no long stage after it. Leaving Download clears the measured speed. Cards
and the game page follow the active stage's percent.
- **The art is the card** (maintainer feedback): a store card is its art edge to edge, sharp above
and, under the one line, a blurred and darkened copy of the same picture (blur on API 31+, a
stronger scrim below it). A Downloads row is the game's wide art cropped to the row with a dark
wash from the left, the copy in white there and the actions on the right; no thumbnail.
- **Install dialog:** one plain line "Install <game>:", then one row per place (icon, name, free
space), Cancel small in the title line; 440 dp wide.
- **No flavor text** (standing rule from the maintainer): Setup › Stores and the cog popup keep
only control labels; the download-controls caption, the Downloads footnote, the sign-in blurbs
and footnote, the engine note and the Install-to caption are gone; empty states read "No games",
"Nothing installed", "No downloads", "No catalog". A Custom game's hero has no eyebrow (its chip
says it).
- **Logos reverted** (user decision, no third-party marks): back to the text source chips and the
coloured dots.
- **Device-proven on the AYANEO Pocket FIT, 2026-10-08 (GOG):** sign-in, the library (33 owned),
DOOM I Enhanced installed through the GOG engine to the SD Games root, shown in Games with the
GOG chip and real art, registered as a non-Steam game in the Steam client (grid art present), and
launched from the Games tab through the shortcut and droiddeck-proton to the main menu at 143 fps.
- Status: CI green (build, JVM and python tests). Epic and Amazon are still unproven on device -
their sign-in pages, an install, and for Epic the launcher .bat with the exchange code are the
next things to prove on hardware.
## 2026-10-08 - `feat/directaudio-from-release`: DirectAudio from its own release, picked by interface, and the client gets the real engine
Three things were wrong with audio at once, and one tidy-up @xXJSONDeruloXx asked for.
- **Proton-CachyOS games never got DirectAudio.** Both CachyOS Protons we offer carry Wine's newer
*system-thread* audio interface (`dlls/mmdevapi/unixlib.h` differs from Valve's); the one driver
we shipped was built for the classic table, and the wrapper only asked "is this Wine 11?", which
CachyOS passes. Now two driver sets ship (`linux-wine11` for Valve Proton 11 / Experimental /
GE-Proton, `linux-wine11-systhread` for Proton-CachyOS) and `steam-compatibility` picks by what
the Proton's own `winepulse.so` imports (`PsCreateSystemThread` only on the system-thread table) -
never by the version string. No set for the interface, or no `winepulse.so`: DirectAudio stays
off and Proton's audio runs. Confirmed on the FIT: Experimental 20260924 and GE-Proton11-7
classic, cachyos-11.0-20261005-slr system-thread.
- **CachyOS also overrode the registry** (device log: `init_driver Loading driver list
L"pulse,alsa"`): its launcher sets `WINE_AUDIO_DRIVER=pulse,alsa` (setdefault) and its mmdevapi
reads that variable before the registry; Valve's and GE's mmdevapi ignore it. The wrapper now
exports `WINE_AUDIO_DRIVER=directaudio,pulse` as well as writing the registry. On CachyOS that
also means DirectAudio engages on a game's first launch, no registry value needed.
- **Some games ran on PulseAudio while the log said DirectAudio.** Two prefixes on the FIT had the
driver linked into `system32` but a pristine `user.reg` with no `Audio` value: Steam runs the
compat tool several times per launch, and a wineserver from an earlier verb still holding the
registry saves its copy over the line we appended. The wrapper now says so when a server is
live. Two stronger fixes were tried on the device and withdrawn the same day: writing the value
through the live server with a bare `wine reg add`, and having Proton create a missing prefix
first (`proton run wineboot`) - the second Proton run inside Steam's launch sequence got the
launch aborted (`KeyboardInterrupt` in Proton, games bounced back to their page, a half-made
prefix). On Valve/GE a first launch therefore still takes DirectAudio from the second run.
- **The Steam client's own sound was "DirectAudio" in name only.** PulseAudio → sink → relay →
AAudio is one hop more than a plain AAudio sink; the only gain was sharing the games' stream.
The daemon runs on the Android side, so DirectAudio's engine can run *in* it:
`module-directaudio-native-sink` (from the DirectAudio release) - the game driver's adaptive
buffer, two-burst floor, primed ring with fades, route-change reopen, watchdog and limiter, one
step from Android. It is now the only route: the *Steam client audio* choice is gone from the
menu (the relay route was one hop more for no gain, and the old "Classic" sink is the automatic
fallback). If the native sink cannot open its stream the daemon keeps running (`.nofail`) and
`PulseAudioComponent.ensureClientSink` loads the plain AAudio sink instead, saying so in
`audio.log`. The relay helper now starts only for games and the microphone.
- **Binaries out of tree** (@xXJSONDeruloXx): the driver sets, the relay helper and both sinks come
from the pinned release in `tools/directaudio/release.env` (`directaudio-linux-v1.1.0`, four
zips, sha256-checked) through `tools/directaudio/fetch.sh`, in CI and `build_local.sh`, like
gamescope. Deleted: `app/src/main/assets/directaudio/` (now generated, ignored),
`tools/directaudio-relay/`, `tools/aaudio-sink/module-directaudio-sink.c` + `da_relay_proto.h`.
`tools/aaudio-sink` keeps only `module-aaudio-sink` (the fallback). The release carries
MaxsTechReview's #338 fixes, credited there.
- Audio bundle stamp bumped so an installed app re-unpacks the modules.
- **Device-proven on the FIT, four cases:** the client's sink opened at 12 ms / 4 ms bursts with
0 underruns after 10 s (`client sink: DirectAudio (module-directaudio-native-sink)`); FEZ on
`cachyos-11.0-20261005-slr` took the system-thread set - Proton log `Loading driver list
L"directaudio,pulse"` → `Selecting driver L"directaudio"`, relay `hello from FEZ.exe`, 12 ms;
FEZ on Proton Experimental 20260924 on `linux-wine11`, relay hello, 12 ms (no regression);
Curse of the Dead Gods on CachyOS from a cold prefix - DirectAudio on its first launch, one
early xrun and the buffer grew 12 → 16 ms. Open: a Thor (20 ms bursts). An added game (Noita,
a Winlator-era folder never launched here before) bounced on launch with and without this
branch's wrapper steps, before Proton wrote a log - its own issue.
## 2026-09-29 - `feat/controller-input`: the pad the way SteamOS has it
Device-tested on the AYN Thor (Katamari under Proton Experimental ARM64).
+64
View File
@@ -0,0 +1,64 @@
# DroidDeck 0.3.2
### Features
- Added **Keep downloads running** toggle, so Steam downloads can continue when Android sleeps. (@jmarti326, @xXJSONDeruloXx, [#335](https://github.com/Droid-Deck/DroidDeck/pull/335))
<img src="media/0.3.2/keep-downloads-running.gif" width="50%" alt="Closing the handheld mid-download and opening it again: Steam's download keeps going while asleep and finishes with the lid shut">
- Added **Native Steam sleep** with dynamic cloud save and wake movie support. (@xXJSONDeruloXx, [#291](https://github.com/Droid-Deck/DroidDeck/pull/291))
<img src="media/0.3.2/native-steam-sleep.gif" width="50%" alt="Octopath Traveler II on the title screen, the device going to sleep, then waking to Steam's wake movie and landing back in the game">
- Added **Adreno 6xx support**, including Adreno 650 (eg: Retroid Pocket 5). (@unbelievableflavour, @jmarti326, [#320](https://github.com/Droid-Deck/DroidDeck/pull/320), [#326](https://github.com/Droid-Deck/DroidDeck/pull/326))
- SD cards and external drives can now be used as full **Steam libraries**. (@maxjivi05, [#388](https://github.com/Droid-Deck/DroidDeck/pull/388))
- Added per-game **Windows components** with automatic dependency recommendations for Steam and non Steam games. (@The412Banner, [#287](https://github.com/Droid-Deck/DroidDeck/pull/287))
<img src="media/0.3.2/windows-components.jpg" width="50%" alt="Windows components for FlatOut 2: DirectX 9 (d3dx9) recommended for this game, above the full list of 66 components">
- Added XNA, PhysX, Games for Windows Live, MSXML and other Windows components without needing to run their original installers. (@The412Banner, [#347](https://github.com/Droid-Deck/DroidDeck/pull/347))
- Added optional **Force SSBS** for ARM64 Proton games on supported CPUs. (@The412Banner, [#328](https://github.com/Droid-Deck/DroidDeck/pull/328))
- Added a detailed **device report** with SoC, GPU, CPU, Vulkan, memory and driver information. (@The412Banner, [#295](https://github.com/Droid-Deck/DroidDeck/pull/295))
- Added **App scale** presets from 75% to 150%. (@xXJSONDeruloXx, [#272](https://github.com/Droid-Deck/DroidDeck/pull/272))
- File Manager can now browse DroidDeck’s Linux filesystem directly. (@The412Banner, [#392](https://github.com/Droid-Deck/DroidDeck/pull/392))
- Added a **Language** setting, with Steam automatically following the selected language. (@maxjivi05, [#284](https://github.com/Droid-Deck/DroidDeck/pull/284))
- Added opt-in **Debugging tools** for automated game/session control, input, UI inspection and repeatable test scenarios. (@xXJSONDeruloXx, [#406](https://github.com/Droid-Deck/DroidDeck/pull/406))
### Improvements
- Steam and games now run on separate Xwayland servers, closer to SteamOS behavior. (@xXJSONDeruloXx, [#344](https://github.com/Droid-Deck/DroidDeck/pull/344))
- DirectAudio is now the default on fresh installs, with major crackling and underrun improvements across both audio modes. (@maxjivi05, [#338](https://github.com/Droid-Deck/DroidDeck/pull/338))
- Steam now preserves edits made to added-game shortcuts, including Target, Start In, name and launch options. (@maxjivi05, [#393](https://github.com/Droid-Deck/DroidDeck/pull/393))
- Steam now uses the full session resolution on displays wider or larger than 1080p. (@xXJSONDeruloXx, [#391](https://github.com/Droid-Deck/DroidDeck/pull/391))
- Improved Snapdragon and Adreno detection on devices with incomplete hardware information. (@The412Banner, [#295](https://github.com/Droid-Deck/DroidDeck/pull/295))
- Improved layouts for small screens and longer translated text. (@xXJSONDeruloXx, @maxjivi05, [#268](https://github.com/Droid-Deck/DroidDeck/pull/268), [#284](https://github.com/Droid-Deck/DroidDeck/pull/284))
- File Manager and file pickers can now navigate upward from game folders, prefixes and remembered locations. (@The412Banner, [#377](https://github.com/Droid-Deck/DroidDeck/pull/377))
- Expanded and polished Spanish, Japanese, Korean, Chinese, French and Russian translations. (@maxjivi05, @starwishHi, @zeedif, @Tak-attack, @kmnkv1, [#284](https://github.com/Droid-Deck/DroidDeck/pull/284), [#286](https://github.com/Droid-Deck/DroidDeck/pull/286), [#234](https://github.com/Droid-Deck/DroidDeck/pull/234), [#314](https://github.com/Droid-Deck/DroidDeck/pull/314), [#324](https://github.com/Droid-Deck/DroidDeck/pull/324))
- Steam and Linux apps now use Android’s system fonts for Chinese, Japanese, Korean, Thai and other missing characters. (@maxjivi05, @0x1428571429, [#374](https://github.com/Droid-Deck/DroidDeck/pull/374), [#252](https://github.com/Droid-Deck/DroidDeck/pull/252))
- Sessions launched from Android frontends now return to that frontend when they close. (@xXJSONDeruloXx, [#300](https://github.com/Droid-Deck/DroidDeck/pull/300))
### Fixed
- Fixed MangoHud reporting roughly double the real battery power draw and incorrect remaining time. (Thanks Russ ❤️)(@xXJSONDeruloXx, [#270](https://github.com/Droid-Deck/DroidDeck/pull/270))
- Fixed slow Steam installs on SD cards and external storage, including long **Reserving space** / **Committing** stages and installs failing to begin. (@maxjivi05, [#388](https://github.com/Droid-Deck/DroidDeck/pull/388), [#410](https://github.com/Droid-Deck/DroidDeck/pull/410))
- Fixed some games staying behind Steam’s black** **loading screen while already running. (@xXJSONDeruloXx, [#401](https://github.com/Droid-Deck/DroidDeck/pull/401))
- Fixed a graphics-memory leak that could kill the session. (@The412Banner, @xXJSONDeruloXx, [#275](https://github.com/Droid-Deck/DroidDeck/pull/275), [#305](https://github.com/Droid-Deck/DroidDeck/pull/305))
- Fixed some added games starting in `C:\windows` instead of their own game folder. (@The412Banner, [#343](https://github.com/Droid-Deck/DroidDeck/pull/343))
- Fixed Firefox and LibreWolf tabs crashing on affected **Android 16** devices. (@The412Banner, [#280](https://github.com/Droid-Deck/DroidDeck/pull/280))
- Fixed resolution presets changing the screen shape, and fixed 16:9 stretch in Steam Deck mode. (@xXJSONDeruloXx, @magarto, [#337](https://github.com/Droid-Deck/DroidDeck/pull/337), [#133](https://github.com/Droid-Deck/DroidDeck/pull/133))
- Fixed several Steam sleep and wake edge cases. (@xXJSONDeruloXx, [#289](https://github.com/Droid-Deck/DroidDeck/pull/289))
- Fixed some new sessions starting with the wrong output size. (@xXJSONDeruloXx, [#357](https://github.com/Droid-Deck/DroidDeck/pull/357))
- Fixed Windows component installation failures and improved controller navigation in the component picker. (@The412Banner, [#347](https://github.com/Droid-Deck/DroidDeck/pull/347))
- Removed the old **Force game windows fullscreen** workaround now that games run on their own Xwayland server. (@xXJSONDeruloXx, [#349](https://github.com/Droid-Deck/DroidDeck/pull/349))
- Hardened the developer environment override so other apps with storage access cannot modify Steam session environment variables. (@The412Banner, [#413](https://github.com/Droid-Deck/DroidDeck/pull/413))
### New contributors
- @unbelievableflavour made their first contribution in [#320](https://github.com/Droid-Deck/DroidDeck/pull/320).
- @Lightfallingonionroom made their first contribution in [#232](https://github.com/Droid-Deck/DroidDeck/pull/232).
- @0x1428571429 made their first contribution in [#252](https://github.com/Droid-Deck/DroidDeck/pull/252).
- @zeedif made their first contribution in [#234](https://github.com/Droid-Deck/DroidDeck/pull/234).
- @Tak-attack made their first contribution in [#314](https://github.com/Droid-Deck/DroidDeck/pull/314).
- @kmnkv1 made their first contribution in [#324](https://github.com/Droid-Deck/DroidDeck/pull/324).
[Full changelog](https://github.com/Droid-Deck/DroidDeck/compare/0.3.1...0.3.2)
Binary file not shown.

After

Width:  |  Height:  |  Size: 6.7 MiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.4 MiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 58 KiB