aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/indicator-power.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/indicator-power.c b/src/indicator-power.c
index 42542cb..bfb625b 100644
--- a/src/indicator-power.c
+++ b/src/indicator-power.c
@@ -502,6 +502,10 @@ get_primary_device (GVariant *devices)
g_debug ("%s: got data from object %s", G_STRFUNC, object_path);
+ /* not battery */
+ if (kind != UP_DEVICE_KIND_BATTERY)
+ continue;
+
if (state == UP_DEVICE_STATE_DISCHARGING)
{
discharging = TRUE;