From e1988a3d3857b4a3c51e9e4b5132e91c188ec28c Mon Sep 17 00:00:00 2001 From: Lars Uebernickel Date: Mon, 10 Dec 2012 13:42:29 +0100 Subject: Remove the snapdecision widget type Always use messageitem instead. --- src/im-phone-menu.c | 12 ++++-------- 1 file changed, 4 insertions(+), 8 deletions(-) (limited to 'src') diff --git a/src/im-phone-menu.c b/src/im-phone-menu.c index ed28023..83363d1 100644 --- a/src/im-phone-menu.c +++ b/src/im-phone-menu.c @@ -164,14 +164,7 @@ im_phone_menu_add_message (ImPhoneMenu *menu, item = g_menu_item_new (title, action_name); - if (g_variant_n_children (actions)) - { - g_menu_item_set_attribute (item, "x-canonical-type", "s", "com.canonical.indicator.messages.snapdecision"); - g_menu_item_set_attribute (item, "x-canonical-message-actions", "v", actions); - } - else - g_menu_item_set_attribute (item, "x-canonical-type", "s", "com.canonical.indicator.messages.messageitem"); - + g_menu_item_set_attribute (item, "x-canonical-type", "s", "com.canonical.indicator.messages.messageitem"); g_menu_item_set_attribute (item, "x-canonical-message-id", "s", id); g_menu_item_set_attribute (item, "x-canonical-subtitle", "s", subtitle); g_menu_item_set_attribute (item, "x-canonical-text", "s", body); @@ -183,6 +176,9 @@ im_phone_menu_add_message (ImPhoneMenu *menu, if (app_icon) g_menu_item_set_attribute (item, "x-canonical-app-icon", "s", app_icon); + if (actions) + g_menu_item_set_attribute (item, "x-canonical-message-actions", "v", actions); + g_menu_prepend_item (menu->message_section, item); g_free (action_name); -- cgit v1.2.3 From e5caa5032da9e5cd41876934f9073e1f3646edd5 Mon Sep 17 00:00:00 2001 From: Lars Uebernickel Date: Mon, 10 Dec 2012 14:30:10 +0100 Subject: Don't show sources in the phone menu --- src/messages-service.c | 4 ---- 1 file changed, 4 deletions(-) (limited to 'src') diff --git a/src/messages-service.c b/src/messages-service.c index d10e98a..27bce4e 100644 --- a/src/messages-service.c +++ b/src/messages-service.c @@ -166,10 +166,6 @@ main (int argc, char ** argv) settings = g_settings_new ("com.canonical.indicator.messages"); applications = im_application_list_new (); - g_signal_connect_swapped (applications, "source-added", - G_CALLBACK (im_phone_menu_add_source), menu); - g_signal_connect_swapped (applications, "source-removed", - G_CALLBACK (im_phone_menu_remove_source), menu); g_signal_connect_swapped (applications, "message-added", G_CALLBACK (im_phone_menu_add_message), menu); g_signal_connect_swapped (applications, "message-removed", -- cgit v1.2.3