G_CALLBACK (modest_ui_actions_on_new_msg), self);
}
+static void
+folder_refreshed_cb (ModestMailOperation *mail_op,
+ TnyFolder *folder,
+ gpointer user_data)
+{
+ /* Update the view (folder could be empty) */
+ update_view (MODEST_HEADER_WINDOW (user_data), NULL);
+}
+
static GtkWidget *
create_header_view (ModestWindow *self, TnyFolder *folder)
{
GtkWidget *header_view;
header_view = modest_header_view_new (NULL, MODEST_HEADER_VIEW_STYLE_TWOLINES);
- modest_header_view_set_folder (MODEST_HEADER_VIEW (header_view), folder,
- TRUE, self, NULL, NULL);
- modest_header_view_set_filter (MODEST_HEADER_VIEW (header_view),
+ modest_header_view_set_folder (MODEST_HEADER_VIEW (header_view), folder,
+ TRUE, self, folder_refreshed_cb, self);
+ modest_header_view_set_filter (MODEST_HEADER_VIEW (header_view),
MODEST_HEADER_VIEW_FILTER_NONE);
modest_widget_memory_restore (modest_runtime_get_conf (), G_OBJECT(header_view),
MODEST_CONF_HEADER_VIEW_KEY);
static GtkWidget *
create_empty_view (ModestWindow *self)
{
+ GtkWidget *viewport = NULL;
GtkWidget *label = NULL;
GtkWidget *align = NULL;
GtkWidget *vbox = NULL;
"clicked",
G_CALLBACK (modest_ui_actions_on_new_msg), self);
- return vbox;
+ viewport = gtk_viewport_new ((GtkAdjustment *) gtk_adjustment_new (0, 0, 0, 0, 0, 0),
+ (GtkAdjustment *) gtk_adjustment_new (0, 0, 0, 0, 0, 0));
+ gtk_container_add (GTK_CONTAINER (viewport), vbox);
+
+ return viewport;
}
static void
ModestWindow *
-modest_header_window_new (TnyFolder *folder, const gchar *account_name)
+modest_header_window_new (TnyFolder *folder, const gchar *account_name, const gchar *mailbox)
{
ModestHeaderWindow *self = NULL;
ModestHeaderWindowPrivate *priv = NULL;
modest_window_set_active_account (MODEST_WINDOW (self), account_name);
+ modest_window_set_active_mailbox (MODEST_WINDOW (self), mailbox);
mgr = modest_runtime_get_account_mgr ();
settings = modest_account_mgr_load_account_settings (mgr, account_name);
if (settings) {
g_signal_connect (G_OBJECT (priv->sort_button), "clicked",
G_CALLBACK (modest_ui_actions_on_sort), (gpointer) self);
hildon_button_set_style(HILDON_BUTTON (priv->sort_button), HILDON_BUTTON_STYLE_PICKER);
+ hildon_button_set_title_alignment (HILDON_BUTTON (priv->sort_button), 0.5, 0.5);
+ hildon_button_set_value_alignment (HILDON_BUTTON (priv->sort_button), 0.5, 0.5);
modest_hildon2_window_add_button_to_menu (MODEST_HILDON2_WINDOW (self), GTK_BUTTON (priv->sort_button),
modest_ui_dimming_rules_on_sort);
modest_hildon2_window_add_to_menu (MODEST_HILDON2_WINDOW (self), _("mcen_me_inbox_sendandreceive"), NULL,
if (has_active_operations (self)) {
priv->progress_hint = TRUE;
+ } else {
+ priv->progress_hint = FALSE;
}
if (!priv->progress_hint && priv->current_store_account) {