diff --git a/themes/icons.lua b/themes/icons.lua index 30cbc9c..260b077 100644 --- a/themes/icons.lua +++ b/themes/icons.lua @@ -47,4 +47,6 @@ beautiful.recolor_icon_group(temp,"^battery_.+",beautiful.fg_normal) beautiful.wallpapers_icon = gears.color.recolor_image(beautiful.icon_dir.."wallpaper.svg",beautiful.fg_normal) beautiful.mailbox_icon = gears.color.recolor_image(beautiful.icon_dir.."mail.svg",beautiful.fg_normal) beautiful.username_logout_icon = gears.color.recolor_image(beautiful.icon_dir.."system-log-out-symbolic.svg",beautiful.fg_normal) +beautiful.drawer_open_icon = gears.color.recolor_image(beautiful.icon_dir.."drawer-open.svg",beautiful.fg_normal) +beautiful.drawer_closed_icon = gears.color.recolor_image(beautiful.icon_dir.."drawer-closed.svg",beautiful.fg_normal) diff --git a/themes/unity/icons/drawer-closed.svg b/themes/unity/icons/drawer-closed.svg new file mode 100644 index 0000000..f55095d --- /dev/null +++ b/themes/unity/icons/drawer-closed.svg @@ -0,0 +1,73 @@ + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/themes/unity/icons/drawer-open.svg b/themes/unity/icons/drawer-open.svg new file mode 100644 index 0000000..02c1d88 --- /dev/null +++ b/themes/unity/icons/drawer-open.svg @@ -0,0 +1,73 @@ + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/widgets/drawer.lua b/widgets/drawer.lua index efde98e..7fcb65d 100644 --- a/widgets/drawer.lua +++ b/widgets/drawer.lua @@ -18,7 +18,7 @@ return function(args) contained_widget, { widget = wibox.widget.imagebox, - image = style["battery_missing_symbolic"], + image = style["drawer_closed_icon"], id = "widget_toggle", resize = true }, @@ -30,7 +30,14 @@ return function(args) awful.util.table.join( awful.button({},1,function() local subwidget = widget:get_children_by_id("contents")[1] + local image = widget:get_children_by_id("widget_toggle")[1] + if not subwidget.visible then + image.image = style["drawer_open_icon"] + else + image.image = style["drawer_closed_icon"] + end subwidget.visible = not subwidget.visible + end) ) )