webengine/widgetregistry/Server/inc/WidgetRegistry.h
changeset 65 5bfc169077b2
parent 37 cb62a4f66ebe
equal deleted inserted replaced
42:d39add9822e2 65:5bfc169077b2
    21 #define WIDGETREGISTRY_H
    21 #define WIDGETREGISTRY_H
    22 
    22 
    23 // INCLUDES
    23 // INCLUDES
    24 #include <e32hashtab.h>
    24 #include <e32hashtab.h>
    25 #include <apgcli.h>
    25 #include <apgcli.h>
    26 #include <browser_platform_variant.hrh>
    26 #include <Browser_platform_variant.hrh>
    27 #include <widgetregistrydata.h>
    27 #include <apgnotif.h>
    28 #include <widgetregistryconstants.h>
    28 #include "WidgetRegistryData.h"
    29 #include <widgetpropertyvalue.h>
    29 #include "WidgetRegistryConstants.h"
       
    30 #include "WidgetPropertyValue.h"
    30 #include "WidgetRegistryLog.h"
    31 #include "WidgetRegistryLog.h"
    31 
    32 
    32 // CONSTANTS
    33 // CONSTANTS
    33 #define KWidgetRegistryMaxPathName 64
    34 #define KWidgetRegistryMaxPathName 64
    34 
    35 
    35 // MACROS
    36 // MACROS
    36 
    37 
    37 // FORWARD DECLARATIONS
    38 // FORWARD DECLARATIONS
    38 class RFs;
    39 class RFs;
    39 class CWidgetMMCHandler;
       
    40 class CWidgetEntry;
    40 class CWidgetEntry;
    41 class CWidgetInstaller;
    41 class CWidgetInstaller;
    42 class CWidgetRegistryXml;
    42 class CWidgetRegistryXml;
    43 
    43 
    44 #if defined( BRDO_WRT_SECURITY_MGR_FF )
    44 #if defined( BRDO_WRT_SECURITY_MGR_FF )
    56 /**
    56 /**
    57 *  CWidgetRegistry
    57 *  CWidgetRegistry
    58 *  @since 3.1
    58 *  @since 3.1
    59 */
    59 */
    60 
    60 
    61 class CWidgetRegistry : public CBase
    61 class CWidgetRegistry : public CBase, public MApaAppListServObserver
    62     {
    62     {
    63 public:
    63 public:
    64     /**
    64     /**
    65      * Returns singleton of factory.
    65      * Returns singleton of factory.
    66      */
    66      */
   212 
   212 
   213     /**
   213     /**
   214      * Returns security policyId.
   214      * Returns security policyId.
   215      */
   215      */
   216      TInt SecurityPolicyId() { return FetchSecurityPolicyIdL(); }
   216      TInt SecurityPolicyId() { return FetchSecurityPolicyIdL(); }
   217      
   217 
   218      static void NotifyWidgetAltered();
   218 		//from MApaAppListServObserver
   219      
   219 		void HandleAppListEvent(TInt aEvent);
       
   220 
   220 private:
   221 private:
   221 
   222 
   222     /**
   223     /**
   223      * Insert a widget entry
   224      * Insert a widget entry
   224      */
   225      */
   231 
   232 
   232     /**
   233     /**
   233      * Get widget entry with a particular UId
   234      * Get widget entry with a particular UId
   234      */
   235      */
   235     TInt GetWidgetEntry( const TUid& aUid, CWidgetEntry*& aEntry ) const;
   236     TInt GetWidgetEntry( const TUid& aUid, CWidgetEntry*& aEntry ) const;
   236     
       
   237     /**
       
   238      * Get widget entry with a particular UId
       
   239      */
       
   240     TInt GetWidgetOldEntry( const TUid& aUid, CWidgetEntry*& aEntry ) const;
       
   241 
   237 
   242     /**
   238     /**
   243      * Get widget entry with a particular bundle Id
   239      * Get widget entry with a particular bundle Id
   244      */
   240      */
   245     TInt GetWidgetEntry(
   241     TInt GetWidgetEntry(
   357 private:
   353 private:
   358 
   354 
   359     RWidgetArray                iEntries;
   355     RWidgetArray                iEntries;
   360     RUidArray                   iUsedUids;
   356     RUidArray                   iUsedUids;
   361     RFs                         iFs; // not owned
   357     RFs                         iFs; // not owned
   362     RPointerArray<CWidgetEntry>        iOldEntries; // Hold the earlier entries from iEntries
       
   363 
   358 
   364     // added for validation purpose
   359     // added for validation purpose
   365     RApaLsSession               iAppArch;
   360     RApaLsSession               iAppArch;
   366     CWidgetInstaller*           iInstaller;
   361     CWidgetInstaller*           iInstaller;
   367     TBuf<KWidgetRegistryMaxPathName> iWidgetInstallPath;
   362     TBuf<KWidgetRegistryMaxPathName> iWidgetInstallPath;
   370     TBuf<KWidgetRegistryMaxPathName> iRegistryXmlTempFileName;
   365     TBuf<KWidgetRegistryMaxPathName> iRegistryXmlTempFileName;
   371     TBuf<KWidgetRegistryMaxPathName> iLprojName;
   366     TBuf<KWidgetRegistryMaxPathName> iLprojName;
   372 
   367 
   373     // map of language code to lproj dir
   368     // map of language code to lproj dir
   374     RPtrHashMap<TInt,HBufC8>    iLangDirList;
   369     RPtrHashMap<TInt,HBufC8>    iLangDirList;
   375     CWidgetMMCHandler*          iMMCHandler;
       
   376     TInt                        iPolicyId;
   370     TInt                        iPolicyId;
   377     CWidgetRegistryXml*         iXmlProcessor;
   371     CWidgetRegistryXml*         iXmlProcessor;
       
   372     CApaAppListNotifier* iApaAppListNotifier;
   378 public:
   373 public:
   379     LOG_MEMBER_VARS
   374     LOG_MEMBER_VARS
   380     };
   375     };
   381 
   376 
   382 #endif  //WIDGETREGISTRY_H
   377 #endif  //WIDGETREGISTRY_H