Move messages from the viewer if the source folder is local
[modest] / src / maemo / modest-main-window.c
index 6de49fc..66eddc8 100644 (file)
@@ -354,6 +354,10 @@ modest_main_window_init (ModestMainWindow *obj)
        priv->sighandlers = NULL;
        priv->updating_banner = NULL;
        priv->updating_banner_timeout = 0;
+       
+       modest_window_mgr_register_help_id (modest_runtime_get_window_mgr(),
+                                           GTK_WINDOW(obj),
+                                           "applications_email_mainview");
 }
 
 static void
@@ -1659,7 +1663,7 @@ create_details_widget (GtkWidget *styled_widget, TnyAccount *account)
                TnyAccount *account = TNY_ACCOUNT(folder_store);
                
                time_t last_updated;
-               gchar *last_updated_string;
+               const gchar *last_updated_string;
                /* Get last updated from configuration */
                last_updated = modest_account_mgr_get_last_updated (modest_runtime_get_account_mgr (), 
                                                                    tny_account_get_id (account));
@@ -1674,7 +1678,6 @@ create_details_widget (GtkWidget *styled_widget, TnyAccount *account)
                label_w = gtk_label_new (NULL);
                gtk_label_set_markup (GTK_LABEL (label_w), label);
                gtk_box_pack_start (GTK_BOX (vbox), label_w, FALSE, FALSE, 0);
-               g_free (last_updated_string);
                g_free (label);
        }
 
@@ -2285,9 +2288,15 @@ static void
 refresh_account (const gchar *account_name)
 {
        ModestWindow *win;
-
-       win = MODEST_WINDOW (modest_window_mgr_get_main_window (modest_runtime_get_window_mgr ()));
-
+       
+       /* win must already exists here, obviously */ 
+       win = modest_window_mgr_get_main_window (modest_runtime_get_window_mgr (),
+                                                FALSE);
+       if (!win) {
+               g_warning ("%s: BUG: no main window!", __FUNCTION__);
+               return;
+       }
+       
        /* If account_name == NULL, we must update all (option All) */
        if (!account_name)
                modest_ui_actions_do_send_receive_all (win);