* Fixes NB#81095, UI is now properly updated when deleting an account while retrievi...
[modest] / src / modest-tny-account-store.c
index 5d8307e..e0cd50b 100644 (file)
@@ -539,6 +539,7 @@ show_wrong_password_dialog (TnyAccount *account)
        }
        
        dialog = modest_tny_account_store_show_account_settings_dialog (self, modest_account_name);
+       modest_account_settings_dialog_save_password (MODEST_ACCOUNT_SETTINGS_DIALOG (dialog));
        /* Show an explanatory temporary banner: */
        modest_platform_information_banner (GTK_WIDGET(dialog), NULL, _("mcen_ib_username_pw_incorrect"));
 }
@@ -1642,6 +1643,9 @@ on_account_disconnect_when_removing (TnyCamelAccount *account,
        /* Unref the extra reference added by get_server_account */
        g_object_unref (account);
 
+       /* Cancel all pending operations */
+       tny_account_cancel (TNY_ACCOUNT (account));
+
        /* Clear the cache if it's an store account */
        if (TNY_IS_STORE_ACCOUNT (account))
                tny_store_account_delete_cache (TNY_STORE_ACCOUNT (account));