javaextensions/satsa/pki/src.s60/cstscredentialmanager.cpp
changeset 69 773449708c84
parent 61 bf7ee68962da
child 66 2455ef1f5bbc
--- a/javaextensions/satsa/pki/src.s60/cstscredentialmanager.cpp	Wed Aug 18 09:43:15 2010 +0300
+++ b/javaextensions/satsa/pki/src.s60/cstscredentialmanager.cpp	Thu Sep 02 20:20:40 2010 +0300
@@ -32,10 +32,15 @@
 #include <charconv.h>
 #include <pkcs10.h>
 #include <secdlg.h>
+
+#ifndef RD_JAVA_S60_RELEASE_10_1_ONWARDS
 #include <PKIDlg.h>
+#endif
+
 #include <securityerr.h>
 
 
+
 // CONSTANTS
 _LIT(KSTSSymbianKeyStoreLabel, "Software key store");
 _LIT(KSTSSymbianCertificateStoreLabel, "Software certificate store");
@@ -66,7 +71,12 @@
 {
     delete iEncodedCert;
     delete iIssuerAndSerialNumber;
-    
+#ifndef RD_JAVA_S60_RELEASE_10_1_ONWARDS	
+    if (iPKIDialog)
+    {
+        iPKIDialog->Release();
+    }
+#endif
     delete iDistinguishedName;
     delete iDisplayName;
     delete iRequestEncoded;
@@ -529,7 +539,9 @@
 //
 void CSTSCredentialManager::ConstructL()
 {
-    
+	#ifndef RD_JAVA_S60_RELEASE_10_1_ONWARDS
+    iPKIDialog = PKIDialogFactory::CreateNoteL();
+ #endif
     User::LeaveIfError(iFileServer.Connect());
     iWait = new(ELeave) CActiveSchedulerWait;
     iStore = CUnifiedCertStore::NewL(iFileServer, ETrue);
@@ -614,7 +626,10 @@
     {
         // not found, ok to add
         iState = EAddDialog;
-                        
+        #ifndef RD_JAVA_S60_RELEASE_10_1_ONWARDS
+        iPKIDialog->SaveCertificate(EX509Certificate, EUserCertificate,
+                                    iSubject, iStatus);
+        #endif
         SetActive();
         return;
     }
@@ -714,8 +729,9 @@
     CCTCertInfo* certInfo = (*iCertInfoArray)[ 0 ];
     iState = ERemoveDialog;
     iHandle = certInfo->Handle();
-    
-    
+    #ifndef RD_JAVA_S60_RELEASE_10_1_ONWARDS
+    iPKIDialog->DeleteCertificate(iHandle, iStatus);
+    #endif
     SetActive();
 }
 
@@ -777,8 +793,9 @@
     }
     iState = ECSRDialog;
     iHandle = iKeyInfo->Handle();
-
-   
+		#ifndef RD_JAVA_S60_RELEASE_10_1_ONWARDS
+    iPKIDialog->CreateCSR(*iDisplayName, iHandle, iStatus);
+    #endif
     SetActive();
 
 }
@@ -1022,5 +1039,3 @@
     FunctionServer::doServerSideInit();
 
 }
-
-