Revision: 201029 RCL_3
authorDremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
Thu, 19 Aug 2010 10:46:29 +0300
branchRCL_3
changeset 52 418d2f9448b9
parent 47 02db64fb1712
child 53 3d94ea3e909b
Revision: 201029 Kit: 201033
languageinterworkingfw/servicehandler/EABI/liwServiceHandlerU.DEF
languageinterworkingfw/servicehandler/bwins/liwServiceHandlerU.DEF
languageinterworkingfw/servicehandler/inc/liwservicehandlerimpl.h
languageinterworkingfw/servicehandler/src/liwservicehandler.cpp
languageinterworkingfw/servicehandler/src/liwservicehandlerimpl.cpp
serviceapifw_plat/liw_service_handler_api/inc/liwservicehandler.h
--- a/languageinterworkingfw/servicehandler/EABI/liwServiceHandlerU.DEF	Tue May 11 17:01:39 2010 +0300
+++ b/languageinterworkingfw/servicehandler/EABI/liwServiceHandlerU.DEF	Thu Aug 19 10:46:29 2010 +0300
@@ -224,4 +224,5 @@
 	_ZN11TLiwVariant3SetEx @ 223 NONAME
 	_ZNK11TLiwVariant3GetERx @ 224 NONAME
 	_ZNK11TLiwVariant8AsTInt64Ev @ 225 NONAME
+	_ZN18CLiwServiceHandler7AttachLERK13RPointerArrayI16CLiwCriteriaItemER22CRTSecMgrScriptSessioni @ 226 NONAME
 
--- a/languageinterworkingfw/servicehandler/bwins/liwServiceHandlerU.DEF	Tue May 11 17:01:39 2010 +0300
+++ b/languageinterworkingfw/servicehandler/bwins/liwServiceHandlerU.DEF	Thu Aug 19 10:46:29 2010 +0300
@@ -180,4 +180,5 @@
 	?AsTInt64@TLiwVariant@@QBE_JXZ @ 179 NONAME ; long long TLiwVariant::AsTInt64(void) const
 	?Get@TLiwVariant@@QBEHAA_J@Z @ 180 NONAME ; int TLiwVariant::Get(long long &) const
 	?Set@TLiwVariant@@QAEX_J@Z @ 181 NONAME ; void TLiwVariant::Set(long long)
+	?AttachL@CLiwServiceHandler@@QAEHABV?$RPointerArray@VCLiwCriteriaItem@@@@AAVCRTSecMgrScriptSession@@H@Z @ 182 NONAME ; int CLiwServiceHandler::AttachL(class RPointerArray<class CLiwCriteriaItem> const &, class CRTSecMgrScriptSession &, int)
 
--- a/languageinterworkingfw/servicehandler/inc/liwservicehandlerimpl.h	Tue May 11 17:01:39 2010 +0300
+++ b/languageinterworkingfw/servicehandler/inc/liwservicehandlerimpl.h	Thu Aug 19 10:46:29 2010 +0300
@@ -102,6 +102,7 @@
         TInt AttachL(const RCriteriaArray& aInterest);
         
         TInt AttachL(const RCriteriaArray& aInterest,CRTSecMgrScriptSession* aSecMgrScriptSession);
+        TInt AttachL(const RCriteriaArray& aInterest,CRTSecMgrScriptSession* aSecMgrScriptSession,TInt aWidgetId);
         /**
         * @see CLiwServiceHandler::QueryImplementationL() 
         */
@@ -411,6 +412,9 @@
         // Resource offset for LiwServiceHandler.rsc.
         TInt iResourceOffset;
         
+        // Resource offset for LiwServiceHandler.rsc.
+        TInt iWidgetId;
+        
         // Owns all the providers currently in memory.
         RPointerArray<CLiwServiceIfBase> iProviders;  
           
--- a/languageinterworkingfw/servicehandler/src/liwservicehandler.cpp	Tue May 11 17:01:39 2010 +0300
+++ b/languageinterworkingfw/servicehandler/src/liwservicehandler.cpp	Thu Aug 19 10:46:29 2010 +0300
@@ -101,6 +101,11 @@
     return (iImpl->AttachL(aInterest,&aSecMgrScriptSession));
     }
 
+EXPORT_C TInt CLiwServiceHandler::AttachL(const RCriteriaArray& aInterest,CRTSecMgrScriptSession& aSecMgrScriptSession,TInt aWidgetId)
+    {
+    return (iImpl->AttachL(aInterest,&aSecMgrScriptSession,aWidgetId));
+    }
+
 EXPORT_C void CLiwServiceHandler::GetInterest(RCriteriaArray& aInterest)
     {
     iImpl->GetInterest(aInterest);
--- a/languageinterworkingfw/servicehandler/src/liwservicehandlerimpl.cpp	Tue May 11 17:01:39 2010 +0300
+++ b/languageinterworkingfw/servicehandler/src/liwservicehandlerimpl.cpp	Thu Aug 19 10:46:29 2010 +0300
@@ -37,7 +37,7 @@
 
 #include "liwxmlhandler.h"
 #include "liwservicedata.h"
-
+#include <e32property.h>
 #include <rtsecmgrscriptsession.h>
 
 // CONSTANTS
@@ -54,6 +54,10 @@
 // The whole range that is reserved to all menu panes. Currently value is 170 000.
 const TInt KMenuPaneCommandRange = (KMaxMenuResources + 1) * KIndividualMenuPaneIdRange; 
 
+const TUid KMyPropertyCat = { 0x10282822 };
+
+enum TMyPropertyKeys { EMyPropertyState = 115,  EMyPropertyFinalState = 116};
+
 _LIT(KLiwResourceFile, "liwServiceHandler.rsc");
 _LIT(KLiwZDrive, "z:");
 _LIT8(KDataSeparator, "||");
@@ -427,6 +431,12 @@
     	return (this->AttachL(aInterest,NULL));
     }
 
+TInt CLiwServiceHandlerImpl::AttachL(const RCriteriaArray& aInterest,CRTSecMgrScriptSession* aSecMgrScriptSession,TInt aWidgetId)
+    {
+        iWidgetId = aWidgetId;
+        return (this->AttachL(aInterest,aSecMgrScriptSession));
+    }
+
 TInt CLiwServiceHandlerImpl::AttachL(const RCriteriaArray& aInterest ,CRTSecMgrScriptSession* aSecMgrScriptSession)
     {
     RCriteriaArray interest, filtered;
@@ -2857,11 +2867,17 @@
 	    	    {
 	    	    if(aScriptSession->PromptOption() == RTPROMPTUI_PROVIDER)
 	    	    	{
-	    	    		GetProviderResourceFile(provResourcePath, pServiceData->GetMetaData());
-	    	        isAllowed = aScriptSession->IsAllowed(provCaps, pChosenImpl->ImplementationUid(), provResourcePath);	
-	    	      }
+	    	    	GetProviderResourceFile(provResourcePath, pServiceData->GetMetaData());
+	    	    	RProperty::Set( KMyPropertyCat, EMyPropertyState , iWidgetId );
+	                isAllowed = aScriptSession->IsAllowed(provCaps, pChosenImpl->ImplementationUid(), provResourcePath);	
+	                RProperty::Set( KMyPropertyCat, EMyPropertyFinalState , iWidgetId );
+	    	    	}
                 else
+                    {
+                    RProperty::Set( KMyPropertyCat, EMyPropertyState , iWidgetId );
                     isAllowed = aScriptSession->IsAllowed(provCaps);
+                    RProperty::Set( KMyPropertyCat, EMyPropertyFinalState , iWidgetId );
+                    }
 	    	    }
 	    		
 	    	if(KErrNone==isAllowed)
--- a/serviceapifw_plat/liw_service_handler_api/inc/liwservicehandler.h	Tue May 11 17:01:39 2010 +0300
+++ b/serviceapifw_plat/liw_service_handler_api/inc/liwservicehandler.h	Thu Aug 19 10:46:29 2010 +0300
@@ -433,7 +433,7 @@
         IMPORT_C TInt MenuCmdId(TInt aMenuCmdId) const;
         
         IMPORT_C TInt AttachL(const RCriteriaArray& aInterest,CRTSecMgrScriptSession& aSecMgrScriptSession);
-                
+        IMPORT_C TInt AttachL(const RCriteriaArray& aInterest,CRTSecMgrScriptSession& aSecMgrScriptSession,TInt aWidgetId);        
  	  /**
         * Lists available service implementations
         *