From c97c17600e711bcd78f7b17a754b533b27b8f45d Mon Sep 17 00:00:00 2001 From: Emmanuel Lepage Vallee Date: Thu, 27 Dec 2018 02:04:09 -0500 Subject: [PATCH] rc.lua: Use the new screen requests instead of connect_for_each_screen This will allow themes to better define their capabilities instead of having to rely on the `rc.lua` `set_wallpaper` black box function. --- awesomerc.lua | 12 +++--------- 1 file changed, 3 insertions(+), 9 deletions(-) diff --git a/awesomerc.lua b/awesomerc.lua index fa584b8a8..5d2bd2c10 100644 --- a/awesomerc.lua +++ b/awesomerc.lua @@ -163,7 +163,7 @@ local tasklist_buttons = gears.table.join( end)) -- @DOC_WALLPAPER@ -local function set_wallpaper(s) +screen.connect_signal("request::wallpaper", function(s) -- Wallpaper if beautiful.wallpaper then local wallpaper = beautiful.wallpaper @@ -173,16 +173,10 @@ local function set_wallpaper(s) end gears.wallpaper.maximized(wallpaper, s, true) end -end - --- Re-set wallpaper when a screen's geometry changes (e.g. different resolution) -screen.connect_signal("property::geometry", set_wallpaper) +end) -- @DOC_FOR_EACH_SCREEN@ -awful.screen.connect_for_each_screen(function(s) - -- Wallpaper - set_wallpaper(s) - +screen.connect_signal("request::desktop_decoration", function(s) -- Each screen has its own tag table. awful.tag({ "1", "2", "3", "4", "5", "6", "7", "8", "9" }, s, awful.layout.layouts[1])