yep, more dotfiles

sway: use different inhibit idle strategies for different apps

wiro.world 397cbb61 fe7b4d7f

verified
+8 -8
+8 -8
home-manager/fragments/sway.nix
··· 149 149 titlebar = false; 150 150 commands = 151 151 let 152 - fullscreenAppInhibitIdle = appId: { 152 + inhibitIdle = appId: behaviour: { 153 153 criteria.app_id = "^${appId}$"; 154 - command = "inhibit_idle fullscreen"; 154 + command = "inhibit_idle ${behaviour}"; 155 155 }; 156 156 in 157 157 [ ··· 174 174 command = ''floating enable''; 175 175 } 176 176 177 - # Inhibit IDLE when these are fullscreen 178 - (fullscreenAppInhibitIdle "firefox") 179 - (fullscreenAppInhibitIdle "mpv") 180 - (fullscreenAppInhibitIdle "spotify") 181 - (fullscreenAppInhibitIdle "zen-beta") 182 - (fullscreenAppInhibitIdle "org.jellyfin.JellyfinDesktop") 177 + # Inhibit IDLE when these are in fullscreen or focused 178 + (inhibitIdle "firefox" "fullscreen") 179 + (inhibitIdle "zen-beta" "fullscreen") 180 + (inhibitIdle "spotify" "fullscreen") 181 + (inhibitIdle "mpv" "focus") 182 + (inhibitIdle "org.jellyfin.JellyfinDesktop" "focus") 183 183 ]; 184 184 }; 185 185