X-Git-Url: https://git.madduck.net/etc/awesome.git/blobdiff_plain/ddbf283f0ebbc6772d485fe76c5dccf338d3b837..176f4d75e1749df77aa8929cb79b4865c2fddaa5:/widgets/fs.lua?ds=inline diff --git a/widgets/fs.lua b/widgets/fs.lua index e01aab8..efd31fb 100644 --- a/widgets/fs.lua +++ b/widgets/fs.lua @@ -61,10 +61,11 @@ local function worker(args) fs.notification_preset = args.notification_preset if not fs.notification_preset then - fs.notification_preset = naughty.config.defaults - fs.notification_preset.font = "Monospace 10" - fs.notification_preset.fg = "#FFFFFF" - fs.notification_preset.bg = "#000000" + fs.notification_preset = { + font = "Monospace 10", + fg = "#FFFFFF", + bg = "#000000" + } end helpers.set_map(partition, false) @@ -124,7 +125,7 @@ local function worker(args) helpers.newtimer(partition, timeout, fs.update) - return fs + return setmetatable(fs, { __index = fs.widget }) end return setmetatable(fs, { __call = function(_, ...) return worker(...) end })