fix: battery status display

This commit is contained in:
ineanto 2023-07-10 11:20:37 +02:00
parent 988fc86d82
commit 586de7623c

View file

@ -42,7 +42,7 @@ else:
def color(percent):
if percent < 35:
return colors.get("low")
if percent < 75 and percent > 35:
if percent < 50 and percent > 35:
return colors.get("mid")
if percent > 50:
return colors.get("high")
@ -75,7 +75,7 @@ else:
elif state == "Unknown":
battery = B_UNKNOWN + " " + B_FULL + " "
else:
battery = B_CHARGING + " " + B_MID + " "
battery = B_UNKNOWN + " " + B_MID + " "
display = display.format(color, battery, percentleft)