aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTed Gould <ted@gould.cx>2010-08-05 15:02:17 -0500
committerTed Gould <ted@gould.cx>2010-08-05 15:02:17 -0500
commit593c6b8c70d347a0109b96e968fc6a4eab7f5fb8 (patch)
tree482292d9879c775b012301b324769c154f75385d
parent54c6103dc570dbbee0ba8402d3c7156ac40dc5a4 (diff)
downloadayatana-indicator-application-593c6b8c70d347a0109b96e968fc6a4eab7f5fb8.tar.gz
ayatana-indicator-application-593c6b8c70d347a0109b96e968fc6a4eab7f5fb8.tar.bz2
ayatana-indicator-application-593c6b8c70d347a0109b96e968fc6a4eab7f5fb8.zip
Check for suffix when updating icon as well!
-rw-r--r--src/indicator-application.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/src/indicator-application.c b/src/indicator-application.c
index 31c3aa9..9abfbe6 100644
--- a/src/indicator-application.c
+++ b/src/indicator-application.c
@@ -693,7 +693,12 @@ application_icon_changed (DBusGProxy * proxy, gint position, const gchar * iconn
/* We make a long name using the suffix, and if that
icon is available we want to use it. Otherwise we'll
just use the name we were given. */
- gchar * longname = g_strdup_printf("%s-%s", iconname, PANEL_ICON_SUFFIX);
+ gchar * longname = NULL;
+ if (!g_str_has_suffix(iconname, PANEL_ICON_SUFFIX)) {
+ longname = g_strdup_printf("%s-%s", iconname, PANEL_ICON_SUFFIX);
+ } else {
+ longname = g_strdup(iconname);
+ }
indicator_image_helper_update(app->entry.image, longname);
g_free(longname);