Linux: restore battery state with numbered AC's

This commit is contained in:
Christian Göttsche 2021-10-26 10:58:59 +02:00
parent 3e70de64b3
commit 4374a267be

View File

@ -765,7 +765,7 @@ static void Platform_Battery_getSysData(double* percent, ACPresence* isOnAC) {
if (!now && full && !isnan(capacityLevel))
totalRemain += capacityLevel * fullCharge;
} else if (String_eq(entryName, "AC")) {
} else if (String_startsWith(entryName, "AC")) {
char buffer[2] = {0};
if (*isOnAC != AC_ERROR)
continue;