diff options
| author | Danilo M. <danix@danix.xyz> | 2026-11-16 17:19:17 +0100 |
|---|---|---|
| committer | Danilo M. <danix@danix.xyz> | 2026-11-16 17:19:17 +0100 |
| commit | 6d60c2a0af28afd8bde3fc41c92f759e10845221 (patch) | |
| tree | 9def4223d99a037c797f832a2e7916c8904a4245 /shared | |
| parent | a3fa6524b744ea062ea0197bb3a0fec7ec9c6b54 (diff) | |
| download | quickshell-6d60c2a0af28afd8bde3fc41c92f759e10845221.tar.gz quickshell-6d60c2a0af28afd8bde3fc41c92f759e10845221.zip | |
feat(status): a game on the Xbox turns presentation on
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Diffstat (limited to 'shared')
| -rw-r--r-- | shared/Status.qml | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/shared/Status.qml b/shared/Status.qml index ab45e99..727f32b 100644 --- a/shared/Status.qml +++ b/shared/Status.qml @@ -33,9 +33,10 @@ Singleton { readonly property bool dnd: dndFile.value // Set by the game detector below, on its own file so it never fights the // manual toggle: presentation is the OR, and a game ending clears only its - // half. A manual "on" therefore survives a game session. - readonly property bool gaming: gamingFile.value - readonly property bool presentation: presFile.value || gamingFile.value + // half. A manual "on" therefore survives a game session. status.xbox is + // the same for a game on the Xbox, written by deck-it's xbox module. + readonly property bool gaming: gamingFile.value || xboxFile.value + readonly property bool presentation: presFile.value || gaming // Stored as "auto-lock disabled", so the missing-file default of off is // the wanted default of locking on. The row inverts it for the label. readonly property bool nolock: nolockFile.value @@ -109,7 +110,7 @@ Singleton { // The detector calls this every poll; a write on an unchanged value would // still land as an atomic write and re-fire the FileView watch for nothing. function setGaming(on) { - if (on !== root.gaming) gamingFile.write(on); + if (on !== gamingFile.value) gamingFile.write(on); } // The timed disable re-enables itself. Runs only while a deadline is @@ -234,4 +235,6 @@ Singleton { ModeFile { id: nolampFile; path: root.dir + "/status.nolamp" } // Written only by the game detector above, never by statusctl. ModeFile { id: gamingFile; path: root.dir + "/status.gaming" } + // Written only by deck-it while the Xbox runs a game. + ModeFile { id: xboxFile; path: root.dir + "/status.xbox" } } |
