diff options
| author | Don Williams <don.e.williams@gmail.com> | 2026-07-26 21:24:29 -0400 |
|---|---|---|
| committer | Pinapelz <yukais@pinapelz.com> | 2026-08-29 21:41:34 -0700 |
| commit | 06a6ec5bc87701ced2845a27d322633d2efdbd52 (patch) | |
| tree | 13894e6f09590f60953d8d4e3c2373fff7f25125 /config/hypr | |
| parent | e4203872bb1de4ffc0d5d39c41402f5b8914a995 (diff) | |
Added event driven disable of eDP-1 on lid close
On branch development
Your branch is up to date with 'origin/development'.
Changes to be committed:
modified: config/hypr/UserConfigs/Laptops.conf
modified: config/hypr/UserConfigs/user_laptops.lua
Diffstat (limited to 'config/hypr')
| -rw-r--r-- | config/hypr/UserConfigs/Laptops.conf | 4 | ||||
| -rw-r--r-- | config/hypr/UserConfigs/user_laptops.lua | 10 |
2 files changed, 12 insertions, 2 deletions
diff --git a/config/hypr/UserConfigs/Laptops.conf b/config/hypr/UserConfigs/Laptops.conf index b4e3cbdc..fefc0d80 100644 --- a/config/hypr/UserConfigs/Laptops.conf +++ b/config/hypr/UserConfigs/Laptops.conf @@ -15,8 +15,8 @@ $UserConfigs = $HOME/.config/hypr/UserConfigs # Suggest you edit below for your laptop display # From WIKI This is to disable laptop monitor when lid is closed. # consult https://wiki.hyprland.org/hyprland-wiki/pages/Configuring/Binds/#switches -#bindl = , switch:off:Lid Switch,exec,hyprctl keyword monitor "eDP-1, preferred, auto, 1" -#bindl = , switch:on:Lid Switch,exec,hyprctl keyword monitor "eDP-1, disable" +bindl = , switch:off:Lid Switch,exec,hyprctl keyword monitor "eDP-1, preferred, auto, 1" +bindl = , switch:on:Lid Switch,exec,hyprctl keyword monitor "eDP-1, disable" # WARNING! Using this method has some caveats!! USE THIS PART WITH SOME CAUTION! diff --git a/config/hypr/UserConfigs/user_laptops.lua b/config/hypr/UserConfigs/user_laptops.lua index ac3c7f8c..b75a473f 100644 --- a/config/hypr/UserConfigs/user_laptops.lua +++ b/config/hypr/UserConfigs/user_laptops.lua @@ -10,3 +10,13 @@ -- Examples: -- hl.monitor({ output = "eDP-1", mode = "preferred", position = "auto", scale = "1" }) -- hl.monitor({ output = "eDP-1", disabled = true }) + +-- Lid close: remove laptop panel from layout +hl.bind("switch:on:Lid Switch", function() + hl.monitor({ output = "eDP-1", disabled = true }) +end) + +-- Lid open: restore laptop panel +hl.bind("switch:off:Lid Switch", function() + hl.monitor({ output = "eDP-1", disabled = false }) +end) |
