Home | News | Projects | Releases
Bugs | RFE | Repositories | Help
Enhancement to Modify Account button in the Preferences window.
authorSteve Brokenshire <sbrokenshire@xestia.co.uk>
Wed, 24 Feb 2016 17:43:44 +0000 (17:43 +0000)
committerSteve Brokenshire <sbrokenshire@xestia.co.uk>
Wed, 24 Feb 2016 17:43:44 +0000 (17:43 +0000)
Check for Dialog result in frmEditAccount, don't reload accounts if not
needed to. If needed to reload accounts, also disable the account modify
and account delete buttons as well.

source/frmPreferences.cpp

index 9124004..01a4656 100644 (file)
@@ -127,16 +127,24 @@ void frmPreferences::ModifyABAccount( wxCommandEvent& event )
     frameEditAccount->LoadSettings(AccName);
     frameEditAccount->ShowModal();
 
+    bool DialogResult = frameEditAccount->GetDialogResult();
+
     delete frameEditAccount;
     frameEditAccount = NULL;
     delete cfgfile;
     cfgfile = NULL;
 
+    if (DialogResult == false){
+           return;
+    }
+
     // Reload the account list in the preferences window.
 
     ReloadAccounts();
     *ReloadAccountConfig = TRUE;
-
+    btnAccountModify->Enable(FALSE);
+    btnAccountDelete->Enable(FALSE);
+    
 }
 
 void frmPreferences::DeleteABAccount( wxCommandEvent& event )
Xestia Software Development
Yn Maystri
© 2006 - 2019 Xestia Software Development
Software

Xestia Address Book
Xestia Calendar
Development

Xestia Gelforn
Everything else

About
News
Privacy Policy