Update fullscreen keybinds (use the new fullscreenstate)

This commit is contained in:
ItsDrike 2024-09-23 21:37:34 +02:00
parent cecd965198
commit d4219d9d18
Signed by: ItsDrike
GPG key ID: FA2745890B7048C0
2 changed files with 9 additions and 7 deletions

View file

@ -4,19 +4,19 @@
ACTIVE_BORDER_COLOR="0xFFFF6600"
DEFAULT_BORDER_COLOR="0xFFFFA500"
hyprctl dispatch fakefullscreen ""
hyprctl dispatch fullscreenstate -1 2
fullscreen_status="$(hyprctl activewindow -j | jq '.fakeFullscreen')"
fullscreen_status="$(hyprctl activewindow -j | jq '.fullscreenClient')"
if [ "$fullscreen_status" = "null" ]; then
echo "Update your hyprland, 'fakeFullscreen' window property not found."
exit 1
elif [ "$fullscreen_status" = "true" ]; then
elif [ "$fullscreen_status" = "2" ]; then
window_address="$(hyprctl activewindow -j | jq -r '.address')"
hyprctl setprop "address:$window_address" activebordercolor "$ACTIVE_BORDER_COLOR" lock
elif [ "$fullscreen_status" = "false" ]; then
elif [ "$fullscreen_status" = "0" ]; then
window_address="$(hyprctl activewindow -j | jq -r '.address')"
hyprctl setprop "address:$window_address" activebordercolor "$DEFAULT_BORDER_COLOR"
else
echo "Unexpected output from 'fakeFullscreen' window property: $fullscreen_status"
echo "Unexpected output from 'fullscreenClient' window property: $fullscreen_status"
exit 1
fi