From f19b38d45bd72945739df730eb7e0c34f76ffc86 Mon Sep 17 00:00:00 2001 From: actionless Date: Thu, 14 Jan 2016 16:56:37 +0100 Subject: [PATCH] fix(awful: hotkeys): caching on multiscreen setup --- lib/awful/hotkeys_popup/widget.lua | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/lib/awful/hotkeys_popup/widget.lua b/lib/awful/hotkeys_popup/widget.lua index 3785faaa8..06457e4e4 100644 --- a/lib/awful/hotkeys_popup/widget.lua +++ b/lib/awful/hotkeys_popup/widget.lua @@ -90,7 +90,7 @@ local widget = { } -local cached_wiboxes = {{}} +local cached_wiboxes = {} local cached_awful_keys = nil local colors_counter = {} local colors = beautiful.xresources.get_current_theme() @@ -358,6 +358,9 @@ function widget.show_help(c, s) end local joined_groups = join_plus_sort(available_groups) + if not cached_wiboxes[s] then + cached_wiboxes[s] = {} + end if not cached_wiboxes[s][joined_groups] then cached_wiboxes[s][joined_groups] = create_wibox(s, available_groups) end