$mainMod = SUPER
$altMod = ALT
bind = SUPER, P, exec, /home/inorishio/Documents/Git/What_That_Claude_DO/target/release/rs-pictures
# Main
bind = , code:121, exec, uwsm-app -S out -- wpctl set-mute @DEFAULT_AUDIO_SINK@ toggle
bind = , code:122, exec, uwsm-app -S out -- wpctl set-volume @DEFAULT_AUDIO_SINK@ 0.02-
bind = , code:123, exec, uwsm-app -S out -- wpctl set-volume @DEFAULT_AUDIO_SINK@ 0.02+ --limit 1.0
bind = , PRINT, exec, uwsm-app -S out -- wpctl set-mute @DEFAULT_AUDIO_SOURCE@ toggle
bind = CTRL, PRINT, exec, uwsm-app -S out -- wpctl set-mute @DEFAULT_AUDIO_SINK@ toggle
bind = $mainMod, PRINT, exec, uwsm-app -S out -- wpctl set-volume @DEFAULT_AUDIO_SOURCE@ 0.32
bind = $mainMod, RETURN, exec, uwsm-app -S out -- zterm # Open terminal
bind = $mainMod, B, exec, uwsm-app -S out -- librewolf # Open browser
bind = $mainMod, E, exec, uwsm-app -S out -- dolphin # Open filemanager
bind = $mainMod, V, exec, uwsm-app -S out -- discord # Open Discord
bind = $mainMod, C, exec, uwsm-app -S out -- Telegram # Open Telegram
bind = $mainMod, S, exec, uwsm-app -S out -- spotify-launcher # Open Spotify
bind = $mainMod, X, exec, uwsm-app -S out -- env SDL_VIDEODRIVER="x11" osu-lazer # pen Osu-Lazer!

# Zoom
# bind = $mainMod, Z,          global, hyprlandzoom:toggle-zoom
# bind = $mainMod, mouse_up,   exec,   /home/inorishio/Documents/Git/zooming/I-Zoom/target/debug/I-Zoom step-up
# bind = $mainMod, mouse_down, exec,   /home/inorishio/Documents/Git/zooming/I-Zoom/target/debug/I-Zoom step-down

# bind = $mainMod, mouse_up,   exec, /home/inorishio/Documents/Git/zooming/I-Zoom/target/debug/zoom --zoom-in
# bind = $mainMod, mouse_down, exec, /home/inorishio/Documents/Git/zooming/I-Zoom/target/debug/zoom --zoom-out
# bind = $mainMod SHIFT, Z,    exec, /home/inorishio/Documents/Git/zooming/I-Zoom/target/debug/zoom --toggle
# bind = $mainMod CTRL, Z,     exec, /home/inorishio/Documents/Git/zooming/I-Zoom/target/debug/zoom --reset

bind = $mainMod, mouse_down, exec, hyprctl -q keyword cursor:zoom_factor $(hyprctl getoptions cursor:zoom_factor -j | jq '.float * 1.3')
bind = $mainMod, mouse_up, exec, hyprctl -q keyword cursor:zoom_factor $(hyprctl getoptions cursor:zoom_factor -j | jq '(.float * 0.7) | if . < 1 then 1 else . end')

# Actions
bind = $mainMod CTRL, Q, exec, systemctl poweroff
# bind = $mainMod SHIFT, S, exec, uwsm-app -S out -- hyprshot -m region -o /home/inorishio/Pictures/Screenshots -s
bind = $mainMod, TAB, workspace, m+1 # Open next workspace
bind = $mainMod, Escape, workspace, m-1 # Open previous workspace

# QML
bind = $mainMod, G, global, zshell:toggle-settings
bind = CTRL, mouse:274, exec, ideskpet toggle-region
bind = SHIFT, mouse:274, exec, ideskpet toggle-layer
bind = $mainMod, Z, exec, ideskpet cycle-zindex
bind = $mainMod CTRL, RETURN, global, zshell:toggle-launcher
bind = $mainMod, N, global, zshell:toggle-nc
bind = $mainMod SHIFT, S, global, zshell:screenshot
bind = $mainMod CTRL, S, global, zshell:screenshotFreeze
bind = $mainMod CTRL, N, global, zshell:toggle-dnd
bind = $mainMod CTRL, T, global, zshell:brightnessDown
bind = $mainMod, L, exec, zshell-cli shell lock
bind = $mainMod SHIFT, D, global, zshell:toggle-drawing
bind = $mainMod CTRL SHIFT, R, exec, app2unit -- zshell-cli shell kill; sleep 0.5; app2unit -- zshell-cli shell start

# Mediakeys
bind = $mainMod, code:67, exec, uwsm-app -S out -- playerctl play-pause # F1
bind = $mainMod, code:68, exec, uwsm-app -S out -- playerctl previous # F2
bind = $mainMod, code:69, exec, uwsm-app -S out -- playerctl next # F3
bind = , code:172, exec, uwsm-app -S out -- wpctl set-mute @DEFAULT_AUDIO_SOURCE@ toggle # Mouse sidebutton
bind = , code:171, workspace, m+1 # Mouse upleft
bind = , code:173, workspace, m-1 # Mouse upright

# Windows
bind = $mainMod, Q, killactive # Kill window
bind = $mainMod, F, fullscreen # Fullscreen
bind = $mainMod, T, togglefloating # Toggle float
bind = $mainMod, J, layoutmsg, togglesplit # Toggle split
bind = $mainMod, K, layoutmsg, swapsplit # Swapsplit
bind = $mainMod, left, movefocus, l # Move focus left
bind = $mainMod, right, movefocus, r # Move focus right
bind = $mainMod, up, movefocus, u # Move focus up
bind = $mainMod, down, movefocus, d # Move focus down
bindm = $mainMod, mouse:272, movewindow # Move window with the mouse
bindm = $mainMod, mouse:273, resizewindow # Resize window with the mouse
bind = $mainMod SHIFT, right, resizeactive, 100 0 # Increase window width with keyboard
bind = $mainMod SHIFT, left, resizeactive, -100 0 # Reduce window width with keyboard
bind = $mainMod SHIFT, down, resizeactive, 0 100 # Increase window height with keyboard
bind = $mainMod SHIFT, up, resizeactive, 0 -100 # Reduce window height with keyboard

# Workspaces
bind = $mainMod, 1, workspace, 1
bind = $mainMod, 2, workspace, 2
bind = $mainMod, 3, workspace, 3
bind = $mainMod, 4, workspace, 4
bind = $mainMod, 5, workspace, 5
bind = $mainMod, 6, workspace, 6
bind = $mainMod, 7, workspace, 7
bind = $mainMod, 8, workspace, 8
bind = $mainMod, 9, workspace, 9
bind = $mainMod, 0, workspace, 10

# Move only window to workspace
bind = $mainMod SHIFT, 1, movetoworkspacesilent, 1
bind = $mainMod SHIFT, 2, movetoworkspacesilent, 2
bind = $mainMod SHIFT, 3, movetoworkspacesilent, 3
bind = $mainMod SHIFT, 4, movetoworkspacesilent, 4
bind = $mainMod SHIFT, 5, movetoworkspacesilent, 5
bind = $mainMod SHIFT, 6, movetoworkspacesilent, 6
bind = $mainMod SHIFT, 7, movetoworkspacesilent, 7
bind = $mainMod SHIFT, 8, movetoworkspacesilent, 8
bind = $mainMod SHIFT, 9, movetoworkspacesilent, 9
bind = $mainMod SHIFT, 0, movetoworkspacesilent, 10

# Move with window to workspace
bind = $mainMod CTRL, 1, movetoworkspace, 1
bind = $mainMod CTRL, 2, movetoworkspace, 2
bind = $mainMod CTRL, 3, movetoworkspace, 3
bind = $mainMod CTRL, 4, movetoworkspace, 4
bind = $mainMod CTRL, 5, movetoworkspace, 5
bind = $mainMod CTRL, 6, movetoworkspace, 6
bind = $mainMod CTRL, 7, movetoworkspace, 7
bind = $mainMod CTRL, 8, movetoworkspace, 8
bind = $mainMod CTRL, 9, movetoworkspace, 9
bind = $mainMod CTRL, 0, movetoworkspace, 10
