#include "modest-tny-msg.h"
#include "modest-mail-operation.h"
#include "modest-icon-names.h"
-#include "modest-progress-bar-widget.h"
+#include "modest-progress-bar.h"
#include "modest-text-utils.h"
#include "modest-ui-dimming-manager.h"
#include "maemo/modest-osso-state-saving.h"
toolbar_resize (MODEST_MAIN_WINDOW (self));
/* Add ProgressBar (Transfer toolbar) */
- priv->progress_bar = modest_progress_bar_widget_new ();
+ priv->progress_bar = modest_progress_bar_new ();
gtk_widget_set_no_show_all (priv->progress_bar, TRUE);
placeholder = gtk_ui_manager_get_widget (parent_priv->ui_manager, "/ToolBar/ProgressBarView");
insert_index = gtk_toolbar_get_item_index(GTK_TOOLBAR (parent_priv->toolbar), GTK_TOOL_ITEM(placeholder));
TnyFolderChange *change,
ModestMainWindow *main_window)
{
+ gboolean refilter = FALSE;
gboolean folder_empty = FALSE;
gboolean all_marked_as_deleted = FALSE;
ModestMainWindowPrivate *priv;
if (changed & TNY_FOLDER_CHANGE_CHANGED_ADDED_HEADERS) {
modest_platform_push_email_notification ();
}
+
+ if ((changed) & TNY_FOLDER_CHANGE_CHANGED_EXPUNGED_HEADERS)
+ refilter = TRUE;
+ } else {
+ folder_empty = (((guint) tny_folder_get_all_count (TNY_FOLDER (folder))) == 0);
}
/* Check if all messages are marked to be deleted */
modest_main_window_set_contents_style (main_window,
MODEST_MAIN_WINDOW_CONTENTS_STYLE_HEADERS);
}
+
+ if (refilter)
+ modest_header_view_refilter (header_view);
}
tmp = g_slist_next (tmp);
}
}
+
+ /* Update the main menu as well, we need to explicitely do
+ this in order to enable/disable accelerators */
+ modest_ui_actions_check_menu_dimming_rules (MODEST_WINDOW (self));
}
static void
/* If account_name == NULL, we must update all (option All) */
if (!account_name)
- modest_ui_actions_do_send_receive_all (win, FALSE);
+ modest_ui_actions_do_send_receive_all (win, TRUE);
else
- modest_ui_actions_do_send_receive (account_name, FALSE, win);
+ modest_ui_actions_do_send_receive (account_name, TRUE, win);
}