diff options
author | marosg42 <[email protected]> | 2017-11-07 13:17:11 +0100 |
---|---|---|
committer | raveit65 <[email protected]> | 2017-11-09 10:16:51 +0100 |
commit | 794670a03fd4c3aac6fe72d70ef64aaea9af45d7 (patch) | |
tree | 336acbf1b177951358b9e243287bd661a1016a51 /multiload | |
parent | 9ae17afeec08064ac5513c8e0a64b4c609b7bb13 (diff) | |
download | mate-applets-794670a03fd4c3aac6fe72d70ef64aaea9af45d7.tar.bz2 mate-applets-794670a03fd4c3aac6fe72d70ef64aaea9af45d7.tar.xz |
Update tooltips with latest values
Solving issue #283
Diffstat (limited to 'multiload')
-rw-r--r-- | multiload/main.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/multiload/main.c b/multiload/main.c index cd36de08..e8890f1a 100644 --- a/multiload/main.c +++ b/multiload/main.c @@ -287,8 +287,8 @@ multiload_applet_tooltip_update(LoadGraph *g) if (!strncmp(g->name, "memload", strlen("memload"))) { guint mem_user, mem_cache, user_percent, cache_percent; - mem_user = g->data[0][0]; - mem_cache = g->data[0][1] + g->data[0][2] + g->data[0][3]; + mem_user = g->data[1][0]; + mem_cache = g->data[1][1] + g->data[1][2] + g->data[1][3]; user_percent = 100.0f * mem_user / g->draw_height; cache_percent = 100.0f * mem_cache / g->draw_height; user_percent = MIN(user_percent, 100); @@ -324,7 +324,7 @@ multiload_applet_tooltip_update(LoadGraph *g) guint i, total_used, percent; for (i = 0, total_used = 0; i < (g->n - 1); i++) - total_used += g->data[0][i]; + total_used += g->data[1][i]; percent = 100.0f * total_used / g->draw_height; percent = MIN(percent, 100); |