Home | News | Projects | Releases
Bugs | RFE | Repositories | Help
Check server address matches against the blacklist, bring up dialog if so
[xestiaab/.git] / source / frmNewAccount.cpp
index fa8d6b3..49d278e 100644 (file)
@@ -24,6 +24,7 @@
 
 #include "carddav/carddav.h"
 #include "common/dirs.h"
+#include "common/svrblist.h"
 #include "frmInvalidSSLCertificate.h"
 
 frmNewAccount::frmNewAccount( wxWindow* parent )
@@ -127,6 +128,20 @@ void frmNewAccount::ProcessNext( wxCommandEvent& event )
             
                }
         
+               // Check if server address matches against the blacklist.
+               // Bring up warning message if it does.
+               
+               if (CheckBlacklist(txtServerAddress->GetValue())){
+               
+                       int MessageBoxResult = wxMessageBox(_("The server with the address given does not support the CardDAV protocol properly and shouldn't be used.\n\nData loss is very likely.\n\nDo you still want to continue using this server?"), _("Server warning"), wxYES_NO, this);
+               
+                       if (MessageBoxResult == wxNO){
+                               PageSeek--;
+                               return;
+                       }
+                       
+               }
+               
                btnNext->Disable();
         
                bool ServerResult = FALSE;
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