Do not exclude embedded messages in remove attachment dialogs
authorSergio Villar Senin <svillar@igalia.com>
Thu, 12 Mar 2009 09:41:33 +0000 (09:41 +0000)
committerSergio Villar Senin <svillar@igalia.com>
Thu, 12 Mar 2009 09:41:33 +0000 (09:41 +0000)
pmo-trunk-r7970

src/hildon2/modest-maemo-utils.c
src/hildon2/modest-maemo-utils.h
src/hildon2/modest-msg-edit-window.c
src/hildon2/modest-msg-view-window.c

index b8078f4..efbe29c 100644 (file)
@@ -388,7 +388,7 @@ static gboolean match_all (TnyList *list, GObject *item, gpointer match_data)
 }
 
 gboolean
-modest_maemo_utils_select_attachments (GtkWindow *window, TnyList *att_list)
+modest_maemo_utils_select_attachments (GtkWindow *window, TnyList *att_list, gboolean include_msgs)
 {
        GtkTreeModel *model;
        TnyIterator *iterator;
index 36f3658..271905f 100644 (file)
@@ -151,6 +151,6 @@ void       modest_maemo_utils_set_vbutton_layout (GtkSizeGroup *sizegroup,
 
 GtkWidget *modest_maemo_utils_create_group_box (const gchar *label, GtkWidget *contents);
 
-gboolean   modest_maemo_utils_select_attachments (GtkWindow *window, TnyList *att_list);
+gboolean   modest_maemo_utils_select_attachments (GtkWindow *window, TnyList *att_list, gboolean include_msgs);
 
 #endif /*__MODEST_MAEMO_UTILS_H__*/
index 5c5d37a..c2d2d30 100644 (file)
@@ -2463,7 +2463,7 @@ modest_msg_edit_window_remove_attachments (ModestMsgEditWindow *window,
 
        if (att_list == NULL) {
                att_list = modest_attachments_view_get_attachments (MODEST_ATTACHMENTS_VIEW (priv->attachments_view));
-               if (!modest_maemo_utils_select_attachments (GTK_WINDOW (window), att_list)) {
+               if (!modest_maemo_utils_select_attachments (GTK_WINDOW (window), att_list, TRUE)) {
                        g_object_unref (att_list);
                        return;
                }
index fca8093..025b68f 100644 (file)
@@ -2770,7 +2770,7 @@ modest_msg_view_window_save_attachments (ModestMsgViewWindow *window, TnyList *m
                /* In Hildon 2.2 save and delete operate over all the attachments as there's no
                 * selection available */
                mime_parts = modest_msg_view_get_attachments (MODEST_MSG_VIEW (priv->msg_view));
-               if (!modest_maemo_utils_select_attachments (GTK_WINDOW (window), mime_parts)) {
+               if (!modest_maemo_utils_select_attachments (GTK_WINDOW (window), mime_parts, FALSE)) {
                        g_object_unref (mime_parts);
                        return;
                }
@@ -2886,7 +2886,7 @@ modest_msg_view_window_remove_attachments (ModestMsgViewWindow *window, gboolean
        }
        g_object_unref (iter);
 
-       if (!modest_maemo_utils_select_attachments (GTK_WINDOW (window), mime_parts) ||
+       if (!modest_maemo_utils_select_attachments (GTK_WINDOW (window), mime_parts, TRUE) ||
            tny_list_get_length (mime_parts) == 0) {
                g_object_unref (mime_parts);
                return;