This commit is contained in:
2026-08-09 01:52:54 +07:00
parent 811b94ed72
commit 1a0a59880b
13 changed files with 60 additions and 399 deletions
+3 -8
View File
@@ -1,10 +1,5 @@
#!/bin/bash
# Skip lock if a fullscreen window is active (game, video, etc.)
active=$(xprop -root _NET_ACTIVE_WINDOW 2>/dev/null | awk '{print $NF}')
if [ -n "$active" ] && [ "$active" != "0x0" ]; then
state=$(xprop -id "$active" _NET_WM_STATE 2>/dev/null)
if echo "$state" | grep -q "_NET_WM_STATE_FULLSCREEN"; then
exit 0
fi
fi
# Idle-blanking during fullscreen is suppressed by dpms-inhibit, so this
# script (invoked by xss-lock) is only ever triggered for a real pre-suspend
# lock — always lock, regardless of fullscreen state.
exec ~/.config/i3/scripts/lock-now "$1"