Home | News | Projects | Releases
Bugs | RFE | Repositories | Help
Improved importing support.
[xestiaab/.git] / source / import / import.cpp
index 948f83f..b85c4f6 100644 (file)
@@ -104,6 +104,18 @@ void ImportRun(frmMain *frmMainPtrInc){
        AccountName = frmIC->GetAccount();
        AccountType = frmIC->GetAccountType();
 
+       if (frmIC->GetDialogResult() == FALSE){
+               
+               // User decided not to import. Clean up the
+               // dialog.
+               
+               delete frmIC;
+               frmIC = NULL;
+               frmMainPtrInc->ResumeAllTimers();
+               return;
+               
+       }
+
        delete frmIC;
        frmIC = NULL;
 
@@ -289,10 +301,14 @@ void ImportRun(frmMain *frmMainPtrInc){
        
        if (AccountType != wxT("Local") && AccountType != wxT("local")){
        
-               wxString *AccNamePostEventPtr = new wxString;
+               wxString AccNamePostEvent;
+       
+               AccNamePostEvent.Clear();
+               AccNamePostEvent.Append(AccountName);
+               AccNamePostEvent.Trim();
        
                wxCommandEvent accevent(SYNCACCOUNT);
-               accevent.SetClientData(AccNamePostEventPtr);
+               accevent.SetString(AccNamePostEvent);
        
                wxPostEvent(frmMainPtrInc, accevent);
        
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