From 2cab42047a094b70833bb88b3898703499099710 Mon Sep 17 00:00:00 2001 From: James Westby Date: Sun, 5 Apr 2009 12:03:31 +0100 Subject: Be aware that appinfo can be NULL. --- src/app-menu-item.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'src/app-menu-item.c') diff --git a/src/app-menu-item.c b/src/app-menu-item.c index 4fe3298..4501f43 100644 --- a/src/app-menu-item.c +++ b/src/app-menu-item.c @@ -192,11 +192,11 @@ update_label (AppMenuItem * self) if (priv->count_on_label && !priv->unreadcount < 1) { /* TRANSLATORS: This is the name of the program and the number of indicators. So it would read something like "Mail Client (5)" */ - gchar * label = g_strdup_printf(_("%s (%d)"), g_app_info_get_name(priv->appinfo), priv->unreadcount); + gchar * label = g_strdup_printf(_("%s (%d)"), app_menu_item_get_name(self), priv->unreadcount); gtk_label_set_text(GTK_LABEL(priv->name), label); g_free(label); } else { - gtk_label_set_text(GTK_LABEL(priv->name), g_app_info_get_name(priv->appinfo)); + gtk_label_set_text(GTK_LABEL(priv->name), app_menu_item_get_name(self)); } return; @@ -220,7 +220,7 @@ desktop_cb (IndicateListener * listener, IndicateListenerServer * server, gchar g_return_if_fail(priv->appinfo != NULL); update_label(self); - g_signal_emit(G_OBJECT(self), signals[NAME_CHANGED], 0, g_app_info_get_name(priv->appinfo), TRUE); + g_signal_emit(G_OBJECT(self), signals[NAME_CHANGED], 0, app_menu_item_get_name(self), TRUE); return; } -- cgit v1.2.3