X-Git-Url: https://git.madduck.net/etc/awesome.git/blobdiff_plain/8d3868d7ce528cfc075e246c8935bae2724e0868..2d35f1b5842adc089e28a6332a2bbfc941e9d168:/widget/pulseaudio.lua?ds=inline 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