aboutsummaryrefslogtreecommitdiff
path: root/src/indicator-power.c
diff options
context:
space:
mode:
authorCharles Kerr <charles.kerr@canonical.com>2012-06-01 14:48:05 -0500
committerCharles Kerr <charles.kerr@canonical.com>2012-06-01 14:48:05 -0500
commit66ba8edb03428310abe360f443849cb8e57c3480 (patch)
treee116ada8a3fb76782511a2380b3d9dbd8a1f7028 /src/indicator-power.c
parent99a719aac32c4347c9b250372d887ca94aa56330 (diff)
downloadayatana-indicator-power-66ba8edb03428310abe360f443849cb8e57c3480.tar.gz
ayatana-indicator-power-66ba8edb03428310abe360f443849cb8e57c3480.tar.bz2
ayatana-indicator-power-66ba8edb03428310abe360f443849cb8e57c3480.zip
In indicator-power.c's put_primary_device(), remove dead code.
Diffstat (limited to 'src/indicator-power.c')
-rw-r--r--src/indicator-power.c22
1 files changed, 7 insertions, 15 deletions
diff --git a/src/indicator-power.c b/src/indicator-power.c
index d5735ee..33f49e7 100644
--- a/src/indicator-power.c
+++ b/src/indicator-power.c
@@ -440,32 +440,24 @@ get_primary_device (GSList * devices)
static void
put_primary_device (IndicatorPower *self, IndicatorPowerDevice *device)
{
- GIcon *device_gicon;
- gchar *short_details = NULL;
- gchar *details = NULL;
- gchar *accessible_name = NULL;
IndicatorPowerPrivate * priv = self->priv;
/* set icon */
- device_gicon = indicator_power_device_get_gicon (device);
+ GIcon * device_gicon = indicator_power_device_get_gicon (device);
gtk_image_set_from_gicon (priv->status_image, device_gicon, GTK_ICON_SIZE_LARGE_TOOLBAR);
g_clear_object (&device_gicon);
gtk_widget_show (GTK_WIDGET (priv->status_image));
-
- /* get the device name */
- //device_name = device_kind_to_localised_string (kind);
-
/* get the description */
+ gchar * short_details;
+ gchar * details;
+ gchar * accessible_name;
indicator_power_device_get_time_details (device, &short_details, &details, &accessible_name);
-
- gtk_label_set_label (GTK_LABEL (priv->label),
- short_details);
+ gtk_label_set_label (GTK_LABEL (priv->label), short_details);
set_accessible_desc (self, accessible_name);
-
- g_free (short_details);
- g_free (details);
g_free (accessible_name);
+ g_free (details);
+ g_free (short_details);
}
void