From 20af8bdfca5c136ddf146c5315e5f88e917e9b26 Mon Sep 17 00:00:00 2001 From: Julien Danjou Date: Fri, 1 Aug 2008 10:26:13 +0200 Subject: [PATCH] awful: make sel prio over urgent Signed-off-by: Julien Danjou --- lib/awful.lua.in | 16 ++++++---------- 1 file changed, 6 insertions(+), 10 deletions(-) diff --git a/lib/awful.lua.in b/lib/awful.lua.in index f28e0106..cf5e29b4 100644 --- a/lib/awful.lua.in +++ b/lib/awful.lua.in @@ -935,13 +935,9 @@ function P.widget.taglist.label.all(t, bg_focus, fg_focus, bg_urgent, fg_urgent) bg_color = bg_focus fg_color = fg_focus background = "resize=\"true\" image=\"@AWESOME_ICON_PATH@/taglist/squarefw.png\"" - end - for k, c in pairs(client.get()) do - if c:istagged(t) then - if not (sel and sel:istagged(t)) then - background = "resize=\"true\" image=\"@AWESOME_ICON_PATH@/taglist/squarew.png\"" - end - if c.urgent and bg_urgent and fg_urgent then + elseif bg_urgent and fg_urgent then + for k, c in pairs(client.get()) do + if c.urgent and c:istagged(t) then bg_color = bg_urgent fg_color = fg_urgent end @@ -960,10 +956,10 @@ local function widget_tasklist_label_common(c, bg_focus, fg_focus, bg_urgent, fg if c.floating then text = "" end - if c.urgent and bg_urgent and fg_urgent then - text = text .. " "..P.escape(c.name).." " - elseif client.focus_get() == c then + if client.focus_get() == c then text = text .. " "..P.escape(c.name).." " + elseif c.urgent and bg_urgent and fg_urgent then + text = text .. " "..P.escape(c.name).." " else text = text .. " "..P.escape(c.name).." " end