Fixed a few broken names
parent
fb114f52d9
commit
c02e26fb70
|
@ -13,9 +13,9 @@ for i=1, #widget.warnings do
|
|||
widget.warninglog[i] = false
|
||||
end
|
||||
|
||||
widget.image_path = beautiful.icons.widget.missing
|
||||
widget.image_path = beautiful.icons.battery.missing
|
||||
widget.icon = wibox.widget {
|
||||
image = beautiful.icons.widget.missing,
|
||||
image = beautiful.icons.battery.missing,
|
||||
resize = true,
|
||||
widget = wibox.widget.imagebox,
|
||||
}
|
||||
|
@ -107,7 +107,7 @@ widget.update = function(stdout)
|
|||
naughty.notify({
|
||||
title = "Low power",
|
||||
text = "Battery is at " .. tostring(batpec) .. "%",
|
||||
icon = beautiful.icons.widget.caution,
|
||||
icon = beautiful.icons.battery.caution,
|
||||
|
||||
timeout = 5,
|
||||
ignore_suspend = true,
|
||||
|
@ -139,20 +139,20 @@ widget.update = function(stdout)
|
|||
end
|
||||
|
||||
|
||||
widget.image_path = beautiful.icons.widget.missing
|
||||
widget.image_path = beautiful.icons.battery.missing
|
||||
-- Set current battery icon
|
||||
if (not discharging) then
|
||||
if batpec > 80 then widget.image_path = beautiful.icons.widget.charging.full
|
||||
elseif batpec > 60 then widget.image_path = beautiful.icons.widget.charging.good
|
||||
elseif batpec > 40 then widget.image_path = beautiful.icons.widget.charging.low
|
||||
elseif batpec > 20 then widget.image_path = beautiful.icons.widget.charging.caution
|
||||
elseif batpec <= 20 then widget.image_path = beautiful.icons.widget.charging.empty end
|
||||
if batpec > 80 then widget.image_path = beautiful.icons.battery.charging.full
|
||||
elseif batpec > 60 then widget.image_path = beautiful.icons.battery.charging.good
|
||||
elseif batpec > 40 then widget.image_path = beautiful.icons.battery.charging.low
|
||||
elseif batpec > 20 then widget.image_path = beautiful.icons.battery.charging.caution
|
||||
elseif batpec <= 20 then widget.image_path = beautiful.icons.battery.charging.empty end
|
||||
else
|
||||
if batpec > 80 then widget.image_path = beautiful.icons.widget.full
|
||||
elseif batpec > 60 then widget.image_path = beautiful.icons.widget.good
|
||||
elseif batpec > 40 then widget.image_path = beautiful.icons.widget.low
|
||||
elseif batpec > 20 then widget.image_path = beautiful.icons.widget.caution
|
||||
elseif batpec <= 20 then widget.image_path = beautiful.icons.widget.empty end
|
||||
if batpec > 80 then widget.image_path = beautiful.icons.battery.full
|
||||
elseif batpec > 60 then widget.image_path = beautiful.icons.battery.good
|
||||
elseif batpec > 40 then widget.image_path = beautiful.icons.battery.low
|
||||
elseif batpec > 20 then widget.image_path = beautiful.icons.battery.caution
|
||||
elseif batpec <= 20 then widget.image_path = beautiful.icons.battery.empty end
|
||||
end
|
||||
widget.icon.image = widget.image_path
|
||||
|
||||
|
@ -197,7 +197,7 @@ widget.widget:connect_signal("button::press",
|
|||
local out = naughty.notify({
|
||||
title = "Battery:",
|
||||
text = batstat .. batpec .. "%",
|
||||
icon = widget.image_path,
|
||||
icon = widget.icon.image,
|
||||
replaces_id = widget.notid,
|
||||
ignore_suspend = true,
|
||||
|
||||
|
|
Loading…
Reference in New Issue