Skip to content

Commit

Permalink
fix: hack my way around decorations showing the panel
Browse files Browse the repository at this point in the history
it works. it's ugly, but it works.
  • Loading branch information
aarondill committed Sep 6, 2024
1 parent 62ec532 commit 32d5a17
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
1 change: 1 addition & 0 deletions configuration/keys/global.lua
Original file line number Diff line number Diff line change
Expand Up @@ -297,6 +297,7 @@ local globalKeys = gtable.join(
local panel = s and s.top_panel
if not panel then return end
panel.visible = not panel.visible
panel.user_set_hidden = panel.visible == false
end, { description = "Toggle the top panel visiblity", group = "hotkeys" }),
gkey({ modkey, "Shift" }, "`", function()
local s = ascreen.focused() ---@type AwesomeScreenInstance?
Expand Down
5 changes: 3 additions & 2 deletions module/client/decoration.lua
Original file line number Diff line number Diff line change
Expand Up @@ -55,8 +55,9 @@ local function changesOnScreen(currentScreen) ---@param currentScreen AwesomeScr
if client.fullscreen then show_top_bar = false end -- If *any* client is fullscreen, the top panel should be hidden
end

if currentScreen.top_panel then --- Hide bars when app go fullscreen
currentScreen.top_panel.visible = show_top_bar
local panel = currentScreen.top_panel
if panel and not panel.user_set_hidden then --- Hide bars when app go fullscreen
panel.visible = show_top_bar
end
if tag then -- Set the gap to zero if maximized
tag.gap = tag_is_max and 0 or 4
Expand Down

0 comments on commit 32d5a17

Please sign in to comment.