X-Git-Url: https://git.madduck.net/etc/awesome.git/blobdiff_plain/6ebe2d9e72175eee241f6e35e6d59bda770242e7..0493baffd5f17b6331974ae1dac4d404d016e351:/widgets/alsabar.lua diff --git a/widgets/alsabar.lua b/widgets/alsabar.lua index 83e27b5..39bf394 100644 --- a/widgets/alsabar.lua +++ b/widgets/alsabar.lua @@ -127,7 +127,7 @@ local function worker(args) -- Capture mixer control state: [5%] ... ... [on] local volu, mute = string.match(mixer, "([%d]+)%%.*%[([%l]*)") - if (volu and tonumber(volu) ~= alsabar._current_level) or string.match(mute, "on") ~= alsabar._muted + if (volu and tonumber(volu) ~= alsabar._current_level) or (mute and string.match(mute, "on") ~= alsabar._muted) then alsabar._current_level = tonumber(volu) alsabar.bar:set_value(alsabar._current_level / 100)