From a94288f2040965815eb2345b940a736632a06aaa Mon Sep 17 00:00:00 2001 From: Lars Uebernickel Date: Thu, 20 Sep 2012 10:25:00 +0200 Subject: device.c: include gi18n-lib.h instead of gi18n.h The former calls the 'd' variants of the gettext functions and passes the libraries domain in each call. --- src/device.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src') diff --git a/src/device.c b/src/device.c index c22aae8..078c7a4 100644 --- a/src/device.c +++ b/src/device.c @@ -25,7 +25,7 @@ License along with this library. If not, see #include "config.h" #endif -#include +#include #include "device.h" -- cgit v1.2.3 From e4002d584ae850b9c5e546fb638efe94a8e2b361 Mon Sep 17 00:00:00 2001 From: Lars Uebernickel Date: Tue, 25 Sep 2012 09:58:35 +0200 Subject: get_icon: Plug memory leak --- src/indicator-power.c | 1 + 1 file changed, 1 insertion(+) (limited to 'src') diff --git a/src/indicator-power.c b/src/indicator-power.c index f3a7235..9829839 100644 --- a/src/indicator-power.c +++ b/src/indicator-power.c @@ -508,6 +508,7 @@ get_image (IndicatorObject *io) gicon = g_themed_icon_new (DEFAULT_ICON); priv->status_image = GTK_IMAGE (gtk_image_new_from_gicon (gicon, GTK_ICON_SIZE_LARGE_TOOLBAR)); + g_object_unref (gicon); } return priv->status_image; -- cgit v1.2.3 From 2b046e762cb8166c9b11af187835126094ff118d Mon Sep 17 00:00:00 2001 From: Charles Kerr Date: Wed, 3 Oct 2012 11:30:18 -0500 Subject: when discharging the battery, prefer the percent-charged icons over the full,good,low icons because the former show a more accurate view of the charge. --- src/device.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'src') diff --git a/src/device.c b/src/device.c index 078c7a4..898e18f 100644 --- a/src/device.c +++ b/src/device.c @@ -390,8 +390,9 @@ indicator_power_device_get_icon_names (const IndicatorPowerDevice * device) suffix_str = get_device_icon_suffix (percentage); index_str = get_device_icon_index (percentage); - g_ptr_array_add (names, g_strdup_printf ("battery-%s-symbolic", suffix_str)); + g_ptr_array_add (names, g_strdup_printf ("%s-%s", kind_str, index_str)); g_ptr_array_add (names, g_strdup_printf ("gpm-%s-%s", kind_str, index_str)); + g_ptr_array_add (names, g_strdup_printf ("battery-%s-symbolic", suffix_str)); g_ptr_array_add (names, g_strdup_printf ("battery-%s", suffix_str)); break; -- cgit v1.2.3