fix: remove dim step that leaks orphaned layer surfaces
dim creates a wlr-layer-shell surface that Hyprland never cleans up when the process exits — leaves an opaque full-screen overlay (pid=-1) covering the entire display until the layer tree is rebuilt. Removing step 1 (dim) from hypridle prevents future occurrences. unstick-display.sh now restarts waybar to force a layer tree rebuild as a recovery measure.
This commit is contained in:
parent
7d2a0100e9
commit
7e9bf498ff
2 changed files with 5 additions and 10 deletions
|
|
@ -8,16 +8,7 @@ general {
|
||||||
after_sleep_cmd = hyprctl dispatch dpms off && sleep 1 && hyprctl dispatch dpms on
|
after_sleep_cmd = hyprctl dispatch dpms off && sleep 1 && hyprctl dispatch dpms on
|
||||||
}
|
}
|
||||||
|
|
||||||
# Step 1: Dim monitor at 115 sec idle (warning that it will lock soon)
|
# Step 1: Lock screen at 2 min idle
|
||||||
listener {
|
|
||||||
timeout = 115
|
|
||||||
# Only dims the screen, does not lock yet
|
|
||||||
# This shows you that lock will happen soon
|
|
||||||
on-timeout = dim
|
|
||||||
on-resume = pkill -x dim
|
|
||||||
}
|
|
||||||
|
|
||||||
# Step 2: Lock screen at 2 min idle
|
|
||||||
listener {
|
listener {
|
||||||
timeout = 120
|
timeout = 120
|
||||||
on-timeout = ~/.config/hypr/scripts/lock.sh
|
on-timeout = ~/.config/hypr/scripts/lock.sh
|
||||||
|
|
|
||||||
|
|
@ -28,4 +28,8 @@ hyprctl dispatch dpms off
|
||||||
sleep 1
|
sleep 1
|
||||||
hyprctl dispatch dpms on
|
hyprctl dispatch dpms on
|
||||||
|
|
||||||
|
# Force a layer tree rebuild to clear orphaned surfaces (e.g. dim_layer)
|
||||||
|
pkill -x waybar 2>/dev/null
|
||||||
|
hyprctl dispatch exec waybar 2>/dev/null
|
||||||
|
|
||||||
echo "Done. Switch back to Hyprland (Ctrl+Alt+F2)."
|
echo "Done. Switch back to Hyprland (Ctrl+Alt+F2)."
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue