From 40b99f3e6fc6170da525c88cf79186cd9cb565de Mon Sep 17 00:00:00 2001 From: Lars Uebernickel Date: Tue, 4 Dec 2012 18:33:55 +0000 Subject: Only expose one application icon (the -symbolic one) --- src/im-application-list.c | 14 ++++---------- src/im-phone-menu.c | 4 ---- src/im-phone-menu.h | 1 - 3 files changed, 4 insertions(+), 15 deletions(-) (limited to 'src') diff --git a/src/im-application-list.c b/src/im-application-list.c index da78813..64b15e3 100644 --- a/src/im-application-list.c +++ b/src/im-application-list.c @@ -302,8 +302,7 @@ im_application_list_class_init (ImApplicationListClass *klass) NULL, NULL, g_cclosure_marshal_generic, G_TYPE_NONE, - 11, - G_TYPE_STRING, + 10, G_TYPE_STRING, G_TYPE_STRING, G_TYPE_STRING, @@ -578,7 +577,6 @@ im_application_list_message_added (Application *app, GSimpleAction *action; GIcon *app_icon; gchar *app_iconstr = NULL; - gchar *symbolic_app_iconstr = NULL; GVariant *actions = NULL; g_variant_get (message, "(&s&s&s&s&sxaa{sv}b)", @@ -586,10 +584,7 @@ im_application_list_message_added (Application *app, app_icon = g_app_info_get_icon (G_APP_INFO (app->info)); if (app_icon) - { - app_iconstr = g_icon_to_string (app_icon); - symbolic_app_iconstr = get_symbolic_app_icon_string (app_icon); - } + app_iconstr = get_symbolic_app_icon_string (app_icon); action = g_simple_action_new (id, G_VARIANT_TYPE_BOOLEAN); g_signal_connect (action, "activate", G_CALLBACK (im_application_list_message_activated), app); @@ -662,12 +657,11 @@ im_application_list_message_added (Application *app, } g_signal_emit (app->list, signals[MESSAGE_ADDED], 0, - app->id, app_iconstr, symbolic_app_iconstr, id, - iconstr, title, subtitle, body, actions, time, draws_attention); + app->id, app_iconstr, id, iconstr, title, + subtitle, body, actions, time, draws_attention); g_variant_iter_free (action_iter); g_free (app_iconstr); - g_free (symbolic_app_iconstr); g_object_unref (action); } diff --git a/src/im-phone-menu.c b/src/im-phone-menu.c index 51467ba..ed28023 100644 --- a/src/im-phone-menu.c +++ b/src/im-phone-menu.c @@ -146,7 +146,6 @@ void im_phone_menu_add_message (ImPhoneMenu *menu, const gchar *app_id, const gchar *app_icon, - const gchar *symbolic_app_icon, const gchar *id, const gchar *iconstr, const gchar *title, @@ -184,9 +183,6 @@ im_phone_menu_add_message (ImPhoneMenu *menu, if (app_icon) g_menu_item_set_attribute (item, "x-canonical-app-icon", "s", app_icon); - if (symbolic_app_icon) - g_menu_item_set_attribute (item, "x-canonical-app-icon-symbolic", "s", symbolic_app_icon); - g_menu_prepend_item (menu->message_section, item); g_free (action_name); diff --git a/src/im-phone-menu.h b/src/im-phone-menu.h index f78e06f..84908e2 100644 --- a/src/im-phone-menu.h +++ b/src/im-phone-menu.h @@ -40,7 +40,6 @@ GMenuModel * im_phone_menu_get_model (ImPhoneMenu *men void im_phone_menu_add_message (ImPhoneMenu *menu, const gchar *app_id, const gchar *app_icon, - const gchar *symbolic_app_icon, const gchar *id, const gchar *iconstr, const gchar *title, -- cgit v1.2.3