diff options
author | Michael Stapelberg <stapelberg@users.noreply.github.com> | 2016-08-29 09:45:15 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2016-08-29 09:45:15 +0200 |
commit | ad8b034e4847056429386eb642b02978a5921ec1 (patch) | |
tree | c49efb14c7983dad7fa215d6d96d6edd56f9b30f /i3status.c | |
parent | 15de209cbaee6827f061e8d2788c9db232012c6b (diff) | |
parent | dc072f9f5353dc8adab14b2de99f0c1abb25e8d8 (diff) |
Merge pull request #140 from tommie/multibatt
Implement aggregates in print_battery_info
Diffstat (limited to 'i3status.c')
-rw-r--r-- | i3status.c | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -664,7 +664,7 @@ int main(int argc, char *argv[]) { CASE_SEC_TITLE("battery") { SEC_OPEN_MAP("battery"); - print_battery_info(json_gen, buffer, atoi(title), cfg_getstr(sec, "path"), cfg_getstr(sec, "format"), cfg_getstr(sec, "format_down"), cfg_getstr(sec, "status_chr"), cfg_getstr(sec, "status_bat"), cfg_getstr(sec, "status_unk"), cfg_getstr(sec, "status_full"), cfg_getint(sec, "low_threshold"), cfg_getstr(sec, "threshold_type"), cfg_getbool(sec, "last_full_capacity"), cfg_getbool(sec, "integer_battery_capacity"), cfg_getbool(sec, "hide_seconds")); + print_battery_info(json_gen, buffer, (strcasecmp(title, "all") == 0 ? -1 : atoi(title)), cfg_getstr(sec, "path"), cfg_getstr(sec, "format"), cfg_getstr(sec, "format_down"), cfg_getstr(sec, "status_chr"), cfg_getstr(sec, "status_bat"), cfg_getstr(sec, "status_unk"), cfg_getstr(sec, "status_full"), cfg_getint(sec, "low_threshold"), cfg_getstr(sec, "threshold_type"), cfg_getbool(sec, "last_full_capacity"), cfg_getbool(sec, "integer_battery_capacity"), cfg_getbool(sec, "hide_seconds")); SEC_CLOSE_MAP; } |