Workaround for volume not being available during startup
This commit is contained in:
parent
daf0f5ab35
commit
9f1d406ac0
|
@ -181,8 +181,10 @@ local function worker(user_args)
|
||||||
elseif mute == 'on' then widget:unmute()
|
elseif mute == 'on' then widget:unmute()
|
||||||
end
|
end
|
||||||
local volume_level = string.match(stdout, "(%d?%d?%d)%%") -- (\d?\d?\d)\%)
|
local volume_level = string.match(stdout, "(%d?%d?%d)%%") -- (\d?\d?\d)\%)
|
||||||
volume_level = string.format("% 3d", volume_level)
|
if volume_level ~= nil then
|
||||||
widget:set_volume_level(volume_level)
|
volume_level = string.format("% 3d", volume_level)
|
||||||
|
widget:set_volume_level(volume_level)
|
||||||
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
function volume:inc(s)
|
function volume:inc(s)
|
||||||
|
|
Loading…
Reference in New Issue