X-Git-Url: https://git.madduck.net/etc/awesome.git/blobdiff_plain/3f854a45f578f0a93d9f561bb8d7f574ab5675ee..586c54a25750fd90d91c15ac8eb818b2613de582:/widget/pulseaudio.lua diff --git a/widget/pulseaudio.lua b/widget/pulseaudio.lua index 44694d1..6c1344d 100644 --- a/widget/pulseaudio.lua +++ b/widget/pulseaudio.lua @@ -6,18 +6,17 @@ --]] -local helpers = require("lain.helpers") -local shell = require("awful.util").shell -local wibox = require("wibox") -local string = { gmatch = string.gmatch, - match = string.match, - format = string.format } -local setmetatable = setmetatable +local helpers = require("lain.helpers") +local shell = require("awful.util").shell +local wibox = require("wibox") +local string = { gmatch = string.gmatch, + match = string.match, + format = string.format } -- PulseAudio volume -- lain.widget.pulseaudio -local function worker(args) +local function factory(args) local pulseaudio = { widget = wibox.widget.textbox() } local args = args or {} local devicetype = args.devicetype or "sink" @@ -59,4 +58,4 @@ local function worker(args) return pulseaudio end -return setmetatable({}, { __call = function(_, ...) return worker(...) end }) +return factory