reverting commit 5366, because of wrong commit reason
authorVivek Sekar <viveksekar@gmail.com>
Tue, 26 Aug 2008 13:26:43 +0000 (13:26 +0000)
committerVivek Sekar <viveksekar@gmail.com>
Tue, 26 Aug 2008 13:26:43 +0000 (13:26 +0000)
pmo-diablo-r5367

src/maemo/modest-account-settings-dialog.c
src/modest-tny-account-store.c
src/widgets/modest-account-settings-dialog.h

index 67bec94..80c4c8e 100644 (file)
@@ -1126,7 +1126,8 @@ on_response (GtkDialog *wizard_dialog,
                                        g_object_unref (store_settings);
                                        g_object_unref (transport_settings);
                                        
-                                       hildon_banner_show_information(NULL, NULL, _("mcen_ib_advsetup_settings_saved"));
+                                       if (!self->save_password)
+                                               hildon_banner_show_information(NULL, NULL, _("mcen_ib_advsetup_settings_saved"));
                                }
                        } else {
                                hildon_banner_show_information (NULL, NULL, _("mail_ib_setting_failed"));
@@ -1187,6 +1188,7 @@ modest_account_settings_dialog_init (ModestAccountSettingsDialog *self)
             G_CALLBACK (on_response), self); 
             
     self->modified = FALSE;
+    self->save_password = FALSE;
 
     /* When this window is shown, hibernation should not be possible, 
         * because there is no sensible way to save the state: */
@@ -1647,6 +1649,15 @@ modest_account_settings_dialog_set_modified (ModestAccountSettingsDialog *dialog
 
 }
 
+void
+modest_account_settings_dialog_save_password (ModestAccountSettingsDialog *dialog)
+{
+       g_return_if_fail (MODEST_IS_ACCOUNT_SETTINGS_DIALOG (dialog));
+
+       dialog->save_password = TRUE;
+}
+
+
 static void
 modest_account_settings_dialog_class_init (ModestAccountSettingsDialogClass *klass)
 {
index f655ded..b0850a8 100644 (file)
@@ -2153,7 +2153,7 @@ modest_tny_account_store_get_transport_account_from_outbox_header(ModestTnyAccou
 
 GtkWidget *
 modest_tny_account_store_show_account_settings_dialog (ModestTnyAccountStore *self,
-                                                      const gchar *account_name)
+                                                     const gchar *account_name)
 {
        ModestTnyAccountStorePrivate *priv;
        gpointer dialog_as_gpointer = NULL;
@@ -2171,6 +2171,7 @@ modest_tny_account_store_show_account_settings_dialog (ModestTnyAccountStore *se
                GtkWidget *dialog;
                dialog = (GtkWidget *) modest_account_settings_dialog_new ();
                settings = modest_account_mgr_load_account_settings (priv->account_mgr, account_name);
+               modest_account_settings_dialog_save_password (MODEST_ACCOUNT_SETTINGS_DIALOG (dialog));
                modest_account_settings_dialog_set_account (MODEST_ACCOUNT_SETTINGS_DIALOG (dialog), settings);
                g_object_unref (settings);
                modest_account_settings_dialog_switch_to_user_info (MODEST_ACCOUNT_SETTINGS_DIALOG (dialog));
index c51d2b6..5e0be24 100644 (file)
@@ -43,6 +43,7 @@ typedef struct {
        ModestAccountSettings *settings;
        
        gboolean modified;
+       gboolean save_password;
        gchar * account_name; /* This may not change. It is not user visible. */
        ModestTransportStoreProtocol incoming_protocol; /* This may not change. */
        ModestTransportStoreProtocol outgoing_protocol; /* This may not change. */