Home | News | Projects | Releases
Bugs | RFE | Repositories | Help
macOS: Implemented support for adding, editing and deleting a CalDAV account
authorSteve Brokenshire <sbrokenshire@xestia.co.uk>
Fri, 29 Dec 2017 12:31:25 +0000 (12:31 +0000)
committerSteve Brokenshire <sbrokenshire@xestia.co.uk>
Fri, 29 Dec 2017 12:31:25 +0000 (12:31 +0000)
projects/osx/XestiaCalendar.xcodeproj/project.pbxproj
source/forms/newaccount/frmNewAccount.cpp
source/forms/newaccount/frmNewAccount.h
source/forms/newaccount/frmNewAccount.mm [new file with mode: 0644]
source/forms/preferences/frmPreferences.cpp
source/objects/CalDAV/CalDAV-XMLProcessing.cpp
source/objects/CalDAV/CalDAV.cpp
source/objects/CalDAV/CalDAV.h

index f943484..50019b2 100644 (file)
                4ABACC9D1B20E968001368B0 /* wxdebug.xcconfig in Resources */ = {isa = PBXBuildFile; fileRef = 4ABACC981B20E968001368B0 /* wxdebug.xcconfig */; };
                4ABACC9E1B20E968001368B0 /* wxrelease.xcconfig in Resources */ = {isa = PBXBuildFile; fileRef = 4ABACC991B20E968001368B0 /* wxrelease.xcconfig */; };
                4ABACC9F1B20E968001368B0 /* Info_cocoa.plist in Resources */ = {isa = PBXBuildFile; fileRef = 4ABACC9A1B20E968001368B0 /* Info_cocoa.plist */; };
                4ABACC9D1B20E968001368B0 /* wxdebug.xcconfig in Resources */ = {isa = PBXBuildFile; fileRef = 4ABACC981B20E968001368B0 /* wxdebug.xcconfig */; };
                4ABACC9E1B20E968001368B0 /* wxrelease.xcconfig in Resources */ = {isa = PBXBuildFile; fileRef = 4ABACC991B20E968001368B0 /* wxrelease.xcconfig */; };
                4ABACC9F1B20E968001368B0 /* Info_cocoa.plist in Resources */ = {isa = PBXBuildFile; fileRef = 4ABACC9A1B20E968001368B0 /* Info_cocoa.plist */; };
+               4B03EDB11FE092D10041DE17 /* frmNewAccount.mm in Sources */ = {isa = PBXBuildFile; fileRef = 4B03EDB01FE092D00041DE17 /* frmNewAccount.mm */; };
+               4B03EDB51FE094F50041DE17 /* frmActivityMgr.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 4B03EDB41FE094F40041DE17 /* frmActivityMgr.cpp */; };
+               4B03EDB61FE096690041DE17 /* CalDAV-XMLProcessing.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 4B03EDA91FDDF1130041DE17 /* CalDAV-XMLProcessing.cpp */; };
+               4B03EDB71FE0966C0041DE17 /* CalDAV.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 4B03EDAA1FDDF1130041DE17 /* CalDAV.cpp */; };
+               4B03EDB91FE096F40041DE17 /* frmMain-Setup.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 4B03EDB81FE096F30041DE17 /* frmMain-Setup.cpp */; };
                4B4A35271F6B2AD400919765 /* Images.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 4B4A35241F6B29EB00919765 /* Images.xcassets */; };
                4B4A352A1F6B2D7E00919765 /* main.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 4B4A35291F6B2D7E00919765 /* main.cpp */; };
                4B4A35311F6B342B00919765 /* bitmapcode.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 4B4A352F1F6B342700919765 /* bitmapcode.cpp */; };
                4B4A35271F6B2AD400919765 /* Images.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 4B4A35241F6B29EB00919765 /* Images.xcassets */; };
                4B4A352A1F6B2D7E00919765 /* main.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 4B4A35291F6B2D7E00919765 /* main.cpp */; };
                4B4A35311F6B342B00919765 /* bitmapcode.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 4B4A352F1F6B342700919765 /* bitmapcode.cpp */; };
                4ABACC991B20E968001368B0 /* wxrelease.xcconfig */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xcconfig; path = wxrelease.xcconfig; sourceTree = "<group>"; };
                4ABACC9A1B20E968001368B0 /* Info_cocoa.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; path = Info_cocoa.plist; sourceTree = "<group>"; };
                4ABACCA11B20ECA8001368B0 /* Xestia Calendar.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = "Xestia Calendar.app"; sourceTree = BUILT_PRODUCTS_DIR; };
                4ABACC991B20E968001368B0 /* wxrelease.xcconfig */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xcconfig; path = wxrelease.xcconfig; sourceTree = "<group>"; };
                4ABACC9A1B20E968001368B0 /* Info_cocoa.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; path = Info_cocoa.plist; sourceTree = "<group>"; };
                4ABACCA11B20ECA8001368B0 /* Xestia Calendar.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = "Xestia Calendar.app"; sourceTree = BUILT_PRODUCTS_DIR; };
+               4B03EDA81FDDF1130041DE17 /* CalDAV.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = CalDAV.h; path = ../../source/objects/CalDAV/CalDAV.h; sourceTree = "<group>"; };
+               4B03EDA91FDDF1130041DE17 /* CalDAV-XMLProcessing.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = "CalDAV-XMLProcessing.cpp"; path = "../../source/objects/CalDAV/CalDAV-XMLProcessing.cpp"; sourceTree = "<group>"; };
+               4B03EDAA1FDDF1130041DE17 /* CalDAV.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = CalDAV.cpp; path = ../../source/objects/CalDAV/CalDAV.cpp; sourceTree = "<group>"; };
+               4B03EDB01FE092D00041DE17 /* frmNewAccount.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; name = frmNewAccount.mm; path = ../../source/forms/newaccount/frmNewAccount.mm; sourceTree = "<group>"; };
+               4B03EDB31FE094F40041DE17 /* frmActivityMgr.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = frmActivityMgr.h; path = ../../source/forms/actmgr/frmActivityMgr.h; sourceTree = "<group>"; };
+               4B03EDB41FE094F40041DE17 /* frmActivityMgr.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = frmActivityMgr.cpp; path = ../../source/forms/actmgr/frmActivityMgr.cpp; sourceTree = "<group>"; };
+               4B03EDB81FE096F30041DE17 /* frmMain-Setup.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = "frmMain-Setup.cpp"; path = "../../source/forms/main/frmMain-Setup.cpp"; sourceTree = "<group>"; };
                4B4A35241F6B29EB00919765 /* Images.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Images.xcassets; sourceTree = "<group>"; };
                4B4A35291F6B2D7E00919765 /* main.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = main.cpp; path = ../../source/main.cpp; sourceTree = "<group>"; };
                4B4A352F1F6B342700919765 /* bitmapcode.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = bitmapcode.cpp; path = ../../source/tools/bitmapcode.cpp; sourceTree = "<group>"; };
                4B4A35241F6B29EB00919765 /* Images.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Images.xcassets; sourceTree = "<group>"; };
                4B4A35291F6B2D7E00919765 /* main.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = main.cpp; path = ../../source/main.cpp; sourceTree = "<group>"; };
                4B4A352F1F6B342700919765 /* bitmapcode.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = bitmapcode.cpp; path = ../../source/tools/bitmapcode.cpp; sourceTree = "<group>"; };
                                4B4A35281F6B2CB200919765 /* src */,
                                4ABACCA11B20ECA8001368B0 /* Xestia Calendar.app */,
                                4A6DA3E21CAC0B3E00A15B3D /* bitmaphelper */,
                                4B4A35281F6B2CB200919765 /* src */,
                                4ABACCA11B20ECA8001368B0 /* Xestia Calendar.app */,
                                4A6DA3E21CAC0B3E00A15B3D /* bitmaphelper */,
+                               4B03EDAD1FDDF56F0041DE17 /* Frameworks */,
                        );
                        sourceTree = "<group>";
                };
                        );
                        sourceTree = "<group>";
                };
+               4B03EDA71FDDEF790041DE17 /* caldav */ = {
+                       isa = PBXGroup;
+                       children = (
+                               4B03EDA91FDDF1130041DE17 /* CalDAV-XMLProcessing.cpp */,
+                               4B03EDAA1FDDF1130041DE17 /* CalDAV.cpp */,
+                               4B03EDA81FDDF1130041DE17 /* CalDAV.h */,
+                       );
+                       name = caldav;
+                       sourceTree = "<group>";
+               };
+               4B03EDAD1FDDF56F0041DE17 /* Frameworks */ = {
+                       isa = PBXGroup;
+                       children = (
+                       );
+                       name = Frameworks;
+                       sourceTree = "<group>";
+               };
+               4B03EDB21FE094DB0041DE17 /* actmgr */ = {
+                       isa = PBXGroup;
+                       children = (
+                               4B03EDB41FE094F40041DE17 /* frmActivityMgr.cpp */,
+                               4B03EDB31FE094F40041DE17 /* frmActivityMgr.h */,
+                       );
+                       name = actmgr;
+                       sourceTree = "<group>";
+               };
                4B4A35281F6B2CB200919765 /* src */ = {
                        isa = PBXGroup;
                        children = (
                4B4A35281F6B2CB200919765 /* src */ = {
                        isa = PBXGroup;
                        children = (
                4B4A35581F6C67C900919765 /* forms */ = {
                        isa = PBXGroup;
                        children = (
                4B4A35581F6C67C900919765 /* forms */ = {
                        isa = PBXGroup;
                        children = (
+                               4B03EDB21FE094DB0041DE17 /* actmgr */,
                                4B4A35BF1F6EFC2500919765 /* calendarselectmonth */,
                                4B4A35791F6C782D00919765 /* preferences */,
                                4B4A35751F6C76F000919765 /* eventeditor */,
                                4B4A35BF1F6EFC2500919765 /* calendarselectmonth */,
                                4B4A35791F6C782D00919765 /* preferences */,
                                4B4A35751F6C76F000919765 /* eventeditor */,
                        isa = PBXGroup;
                        children = (
                                4B4A35641F6C74D600919765 /* frmMain-Window.cpp */,
                        isa = PBXGroup;
                        children = (
                                4B4A35641F6C74D600919765 /* frmMain-Window.cpp */,
+                               4B03EDB81FE096F30041DE17 /* frmMain-Setup.cpp */,
                                4B4A35651F6C74D600919765 /* frmMain.cpp */,
                                4B4A35661F6C74D600919765 /* frmMain.h */,
                        );
                                4B4A35651F6C74D600919765 /* frmMain.cpp */,
                                4B4A35661F6C74D600919765 /* frmMain.h */,
                        );
                        isa = PBXGroup;
                        children = (
                                4B4A356E1F6C75A500919765 /* frmNewAccount.cpp */,
                        isa = PBXGroup;
                        children = (
                                4B4A356E1F6C75A500919765 /* frmNewAccount.cpp */,
+                               4B03EDB01FE092D00041DE17 /* frmNewAccount.mm */,
                                4B4A356F1F6C75A500919765 /* frmNewAccount.h */,
                        );
                        name = newaccount;
                                4B4A356F1F6C75A500919765 /* frmNewAccount.h */,
                        );
                        name = newaccount;
                4B4A35A21F6C904700919765 /* objects */ = {
                        isa = PBXGroup;
                        children = (
                4B4A35A21F6C904700919765 /* objects */ = {
                        isa = PBXGroup;
                        children = (
+                               4B03EDA71FDDEF790041DE17 /* caldav */,
                                4B4A35AD1F6C94F600919765 /* calendarevent */,
                                4B4A35A71F6C94DF00919765 /* calendarobject */,
                                4B4A35A31F6C922700919765 /* calendarlist */,
                                4B4A35AD1F6C94F600919765 /* calendarevent */,
                                4B4A35A71F6C94DF00919765 /* calendarobject */,
                                4B4A35A31F6C922700919765 /* calendarlist */,
                                4B4A35561F6C67C100919765 /* text.cpp in Sources */,
                                4B4A356C1F6C759100919765 /* frmEditAccount.cpp in Sources */,
                                4B4A35541F6C67C100919765 /* random.cpp in Sources */,
                                4B4A35561F6C67C100919765 /* text.cpp in Sources */,
                                4B4A356C1F6C759100919765 /* frmEditAccount.cpp in Sources */,
                                4B4A35541F6C67C100919765 /* random.cpp in Sources */,
+                               4B03EDB11FE092D10041DE17 /* frmNewAccount.mm in Sources */,
+                               4B03EDB61FE096690041DE17 /* CalDAV-XMLProcessing.cpp in Sources */,
                                4B4A355C1F6C67DC00919765 /* frmAbout.cpp in Sources */,
                                4B4A35741F6C75CB00919765 /* frmCalendarEditor.cpp in Sources */,
                                4B4A355C1F6C67DC00919765 /* frmAbout.cpp in Sources */,
                                4B4A35741F6C75CB00919765 /* frmCalendarEditor.cpp in Sources */,
+                               4B03EDB71FE0966C0041DE17 /* CalDAV.cpp in Sources */,
                                4B4A359A1F6C7C6500919765 /* XCCalendarListAccountCtrl.cpp in Sources */,
                                4B4A359A1F6C7C6500919765 /* XCCalendarListAccountCtrl.cpp in Sources */,
+                               4B03EDB51FE094F50041DE17 /* frmActivityMgr.cpp in Sources */,
                                4B4A357C1F6C78FF00919765 /* frmPreferences.cpp in Sources */,
                                4B4A35531F6C67C100919765 /* preferences.cpp in Sources */,
                                4B4A35971F6C7C6500919765 /* XCCalendarDay.cpp in Sources */,
                                4B4A357C1F6C78FF00919765 /* frmPreferences.cpp in Sources */,
                                4B4A35531F6C67C100919765 /* preferences.cpp in Sources */,
                                4B4A35971F6C7C6500919765 /* XCCalendarDay.cpp in Sources */,
                                4B4A35501F6C67C100919765 /* dirs.cpp in Sources */,
                                4B4A35551F6C67C100919765 /* svrblist.cpp in Sources */,
                                4B4A35681F6C74D600919765 /* frmMain.cpp in Sources */,
                                4B4A35501F6C67C100919765 /* dirs.cpp in Sources */,
                                4B4A35551F6C67C100919765 /* svrblist.cpp in Sources */,
                                4B4A35681F6C74D600919765 /* frmMain.cpp in Sources */,
+                               4B03EDB91FE096F40041DE17 /* frmMain-Setup.cpp in Sources */,
                                4B4A35571F6C67C100919765 /* uuid.cpp in Sources */,
                                4B4A35B71F6D036300919765 /* CalendarDataStorage.cpp in Sources */,
                                4B4A35671F6C74D600919765 /* frmMain-Window.cpp in Sources */,
                                4B4A35571F6C67C100919765 /* uuid.cpp in Sources */,
                                4B4A35B71F6D036300919765 /* CalendarDataStorage.cpp in Sources */,
                                4B4A35671F6C74D600919765 /* frmMain-Window.cpp in Sources */,
index 57b14f9..c50cf84 100644 (file)
@@ -504,14 +504,14 @@ void frmNewAccount::RunCalDAVTest( wxCommandEvent &event )
        
        if (testConnection.SSLVerify() == COSSL_UNABLETOVERIFY){
 #if defined(__APPLE__)
        
        if (testConnection.SSLVerify() == COSSL_UNABLETOVERIFY){
 #if defined(__APPLE__)
-               
+        
                testConnection.BypassSSLVerification(true);
                
                testConnection.BypassSSLVerification(true);
                
-               CalDAVServerResult testConnection = testConnection.Connect(false);
+               CalDAVServerResult testConnectionResult = testConnection.Connect(false);
                
                testConnection.BypassSSLVerification(false);
                
                
                testConnection.BypassSSLVerification(false);
                
-               int SSLResult = DisplayTrustPanel(&TestConnection);
+               int SSLResult = DisplayTrustPanel(&testConnection);
                
                if (SSLResult != NSOKButton){
                        
                
                if (SSLResult != NSOKButton){
                        
@@ -519,7 +519,7 @@ void frmNewAccount::RunCalDAVTest( wxCommandEvent &event )
                        lblServerResponse->SetLabel(_("Not applicable"));
                        lblServerSSLResult->SetLabel(_("Used"));
                        lblServerSSLValid->SetLabel(_("No"));
                        lblServerResponse->SetLabel(_("Not applicable"));
                        lblServerSSLResult->SetLabel(_("Used"));
                        lblServerSSLValid->SetLabel(_("No"));
-                       lblConnectionResultText->SetLabel(_("An error occured whilst connnecting: ") + TestConnection.GetErrorMessage());
+                       lblConnectionResultText->SetLabel(_("An error occured whilst connnecting: ") + testConnection.GetErrorMessage());
                        btnPrevious->Enable(true);
                        return;
                        
                        btnPrevious->Enable(true);
                        return;
                        
@@ -532,7 +532,8 @@ void frmNewAccount::RunCalDAVTest( wxCommandEvent &event )
                        switch(evalResult){
                                case kSecTrustResultProceed:
                                        lblServerSSLValid->SetLabel(_("Verified"));
                        switch(evalResult){
                                case kSecTrustResultProceed:
                                        lblServerSSLValid->SetLabel(_("Verified"));
-                                       break;
+                    break;
+                case kSecTrustResultUnspecified:
                                case kSecTrustResultConfirm:
                                        lblServerSSLValid->SetLabel(_("Verified (user)"));
                                        break;
                                case kSecTrustResultConfirm:
                                        lblServerSSLValid->SetLabel(_("Verified (user)"));
                                        break;
@@ -540,10 +541,14 @@ void frmNewAccount::RunCalDAVTest( wxCommandEvent &event )
                                        lblServerSSLValid->SetLabel(_("Unable to verify"));
                        }
                        
                                        lblServerSSLValid->SetLabel(_("Unable to verify"));
                        }
                        
+            lblServerConnResult->SetLabel(_("Connected"));
                        lblServerResponse->SetLabel(_("Not applicable"));
                        lblServerSSLResult->SetLabel(_("Used"));
                        
                        lblServerResponse->SetLabel(_("Not applicable"));
                        lblServerSSLResult->SetLabel(_("Used"));
                        
-                       if (evalResult != kSecTrustResultProceed){
+            btnPrevious->Enable(true);
+            
+                       if (evalResult != kSecTrustResultProceed && evalResult != kSecTrustResultUnspecified){
+                lblConnectionResultText->SetLabel(_("An error occured whilst connnecting: ") + testConnection.GetErrorMessage());
                                return;
                        }
                        
                                return;
                        }
                        
@@ -678,4 +683,4 @@ void frmNewAccount::RunCalDAVTest( wxCommandEvent &event )
        wxCommandEvent resultsEvent(UPDATERESULTS);
        resultsEvent.SetClientData(resultData);
        wxPostEvent(this, resultsEvent);
        wxCommandEvent resultsEvent(UPDATERESULTS);
        resultsEvent.SetClientData(resultData);
        wxPostEvent(this, resultsEvent);
-}
\ No newline at end of file
+}
index ae8c170..c1c75e3 100644 (file)
@@ -76,8 +76,8 @@ class frmNewAccount : public frmNewAccountADT
                void CloseWindow( wxCommandEvent& event );
                void WriteAccountDetails( wxFileConfig *cfgFileIn, wxString accountType, wxString directoryName );
 #if defined(__APPLE__)
                void CloseWindow( wxCommandEvent& event );
                void WriteAccountDetails( wxFileConfig *cfgFileIn, wxString accountType, wxString directoryName );
 #if defined(__APPLE__)
-               int DisplayTrustPanel(ConnectionObject *Connection);
-               SecTrustResultType ProcessResultType(ConnectionObject *Connection);
+               int DisplayTrustPanel(CalDAV *Connection);
+               SecTrustResultType ProcessResultType(CalDAV *Connection);
 #endif
        public:
                /** Constructor */
 #endif
        public:
                /** Constructor */
diff --git a/source/forms/newaccount/frmNewAccount.mm b/source/forms/newaccount/frmNewAccount.mm
new file mode 100644 (file)
index 0000000..5b7d999
--- /dev/null
@@ -0,0 +1,52 @@
+// frmNewAccount.mm - OS X specific functions for frmNewAccount
+//
+// (c) 2012-2015 Xestia Software Development.
+//
+// This file is part of Xestia Address Book.
+//
+// Xestia Address Book is free software: you can redistribute it and/or modify
+// it under the terms of the GNU General Public License as published by the
+// Free Software Foundation, version 3 of the license.
+//
+// Xestia Address Book is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+// GNU General Public License for more details.
+//
+// You should have received a copy of the GNU General Public License along
+// with Xestia Address Book. If not, see <http://www.gnu.org/licenses/>
+
+#import <Foundation/Foundation.h>
+#import <SecurityInterface/SFCertificateTrustPanel.h>
+
+#include "frmNewAccount.h"
+#include "CalDAV.h"
+
+int frmNewAccount::DisplayTrustPanel(CalDAV *Connection){
+       
+       NSInteger ResultValue;
+       
+       SFCertificateTrustPanel *secpanel = [SFCertificateTrustPanel sharedCertificateTrustPanel];
+       
+       [secpanel setDefaultButtonTitle:@"Accept"];
+       [secpanel setAlternateButtonTitle:@"Cancel"];
+       [secpanel setInformativeText: @"This certificate is not trusted. Someone could be trying to eavesdrop on your connection. Do you want to accept this certificate anyway?\n\nAccept and trusting the certificate will fetch and process information as required.\nCancel will close the connection."];
+       [secpanel setShowsHelp:YES];
+       
+       [secpanel setParentWindow:(NSWindow*)this->GetHandle()];
+       
+       ResultValue = [secpanel runModalForTrust:Connection->BuildSSLCollection() message:@"Certificate not trusted"];
+       
+       return (int)ResultValue;
+       
+}
+
+SecTrustResultType frmNewAccount::ProcessResultType(CalDAV *Connection){
+
+       SecTrustResultType EvalResult;
+       
+       SecTrustEvaluate(Connection->BuildSSLCollection(), &EvalResult);
+       
+       return EvalResult;
+       
+}
index 77abeae..fde8e03 100644 (file)
@@ -335,6 +335,12 @@ void frmPreferences::DeleteAccount( wxCommandEvent& event )
                        accountDirDelFull.Append(wxT("\\accounts\\"));
                        accountDirDelFull.Append(accountDirFull);
 
                        accountDirDelFull.Append(wxT("\\accounts\\"));
                        accountDirDelFull.Append(accountDirFull);
 
+#elif defined(__APPLE__)
+            
+            accountDirDelFull.Append(wxString::FromUTF8(getenv("HOME")));
+            accountDirDelFull.Append(wxT("/Library/Preferences/Xestia/Calendar/accounts/"));
+            accountDirDelFull.Append(accountDirFull);
+            
 #else
 
                        accountDirDelFull.Append(wxString::FromUTF8(getenv("HOME")));
 #else
 
                        accountDirDelFull.Append(wxString::FromUTF8(getenv("HOME")));
@@ -440,4 +446,4 @@ void frmPreferences::SetupPointers(bool *reloadAccountInc){
        
        reloadAccountConfig = reloadAccountInc;
 
        
        reloadAccountConfig = reloadAccountInc;
 
-}
\ No newline at end of file
+}
index ab0549b..935bf1c 100644 (file)
@@ -736,4 +736,5 @@ string CalDAV::FetchXMLData(xmlNodePtr *nodePtr){
                        
        }
        
                        
        }
        
-}
\ No newline at end of file
+    return "";
+}
index 48fdb74..3da1e6d 100644 (file)
@@ -201,6 +201,13 @@ CalDAVServerResult CalDAV::Connect(bool doAuthentication){
        switch(serverResult.code){
                case CURLE_OK:
                        authPassed = true;
        switch(serverResult.code){
                case CURLE_OK:
                        authPassed = true;
+            if (connectionData.useSSL)
+            {
+                sslStatus = connectionData.useSSL;
+                sslVerified = COSSL_VERIFIED;
+            }
+            serverResult.result = CALDAVQUERYRESULT_OK;
+            break;
                case CURLE_HTTP_RETURNED_ERROR:
                        if (connectionData.useSSL)
                        {
                case CURLE_HTTP_RETURNED_ERROR:
                        if (connectionData.useSSL)
                        {
@@ -215,6 +222,7 @@ CalDAVServerResult CalDAV::Connect(bool doAuthentication){
                        break;
                case CURLE_SSL_CACERT:
                case CURLE_SSL_CONNECT_ERROR:
                        break;
                case CURLE_SSL_CACERT:
                case CURLE_SSL_CONNECT_ERROR:
+        case CURLE_PEER_FAILED_VERIFICATION:
                        if (connectionData.useSSL)
                        {
                                sslStatus = connectionData.useSSL;
                        if (connectionData.useSSL)
                        {
                                sslStatus = connectionData.useSSL;
@@ -1890,4 +1898,4 @@ void CalDAV::ResetResults(){
                headerList = nullptr;
        }*/
        
                headerList = nullptr;
        }*/
        
-}
\ No newline at end of file
+}
index 377f6ea..eeb84e7 100644 (file)
 #include "../../common/sslcertstructs.h"
 #include "../../version.h"
 
 #include "../../common/sslcertstructs.h"
 #include "../../version.h"
 
+#if defined (__APPLE__)
+#import <Foundation/Foundation.h>
+#import <SecurityInterface/SFCertificateTrustPanel.h>
+#endif
+
 #if defined(__WIN32__)
 #include "../common/win32ssl.h"
 #endif
 #if defined(__WIN32__)
 #include "../common/win32ssl.h"
 #endif
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