From 37d2fb67815f31662df8a6688f72a02664ad4d68 Mon Sep 17 00:00:00 2001 From: Julien Danjou Date: Mon, 23 Feb 2009 14:12:28 +0100 Subject: [PATCH] awful.menu: fix auto_expand Signed-off-by: Julien Danjou --- lib/awful/menu.lua.in | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/lib/awful/menu.lua.in b/lib/awful/menu.lua.in index e3b16930..0bda9f1d 100644 --- a/lib/awful/menu.lua.in +++ b/lib/awful/menu.lua.in @@ -268,7 +268,13 @@ function new(menu, parent, num) data.theme = parent and parent.theme or load_theme(menu) data.parent = parent data.child = {} - data.auto_expand = parent and parent.auto_expand or menu.auto_expand or true + if parent and parent.auto_expand then + data.auto_expand = true + elseif menu.auto_expand ~= nil then + data.auto_expand = menu.auto_expand + else + data.auto_expand = true + end data.h = parent and parent.h or data.theme.menu_height data.w = parent and parent.w or data.theme.menu_width