localisation/apparchitecture/inc/APGAPLST.H
branchSymbian3
changeset 57 b8d18c84f71c
parent 6 c108117318cb
equal deleted inserted replaced
56:aa99f2208aad 57:b8d18c84f71c
     1 // Copyright (c) 1997-2009 Nokia Corporation and/or its subsidiary(-ies).
     1 // Copyright (c) 1997-2009 Nokia Corporation and/or its subsidiary(-ies).
     2 // All rights reserved.
     2 // All rights reserved.
     3 // This component and the accompanying materials are made available
     3 // This component and the accompanying materials are made available
     4 // under the terms of the License "Eclipse Public License v1.0"
     4 // under the terms of "Eclipse Public License v1.0"
     5 // which accompanies this distribution, and is available
     5 // which accompanies this distribution, and is available
     6 // at the URL "http://www.eclipse.org/legal/epl-v10.html".
     6 // at the URL "http://www.eclipse.org/legal/epl-v10.html".
     7 //
     7 //
     8 // Initial Contributors:
     8 // Initial Contributors:
     9 // Nokia Corporation - initial contribution.
     9 // Nokia Corporation - initial contribution.
    10 //
    10 //
    11 // Contributors:
    11 // Contributors:
    12 //
    12 //
    13 // Description:
    13 // Description:
       
    14 // apgaplst.h
    14 //
    15 //
    15 
    16 
    16 #if !defined(__APGAPLST_H__)
    17 #ifndef __APGAPLST_H__
    17 #define __APGAPLST_H__
    18 #define __APGAPLST_H__
    18 
    19 
    19 #if !defined(__APAID_H__)
       
    20 #include <apaid.h>
    20 #include <apaid.h>
    21 #endif
       
    22 #if !defined(__APMSTD_H__)
       
    23 #include <apmstd.h>
    21 #include <apmstd.h>
    24 #endif
       
    25 #if !defined(__BADESCA_H__)
       
    26 #include <badesca.h>
    22 #include <badesca.h>
    27 #endif
       
    28 
       
    29 #include <s32file.h>
    23 #include <s32file.h>
    30 
    24 
    31 // classes defined:
    25 
    32 class CApaAppData;
       
    33 class CApaAppList;
       
    34 class CApaAppViewData;
       
    35 //
       
    36 // classes referenced:
       
    37 class CApaMaskedBitmap;
       
    38 class TEntry;
       
    39 class RFs;
       
    40 class CApaAppRegFinder;
       
    41 class CApaAppIconArray;
       
    42 class CApaIconLoader;
       
    43 //
       
    44 
    26 
    45 /**
    27 /**
    46 KApaMaxAppIcons
    28 KApaMaxAppIcons
    47 
    29 
    48 @publishedPartner
    30 @publishedPartner
    72 @publishedPartner
    54 @publishedPartner
    73 @released
    55 @released
    74 */
    56 */
    75 const TInt KApaIconIndexLarge=2;
    57 const TInt KApaIconIndexLarge=2;
    76 
    58 
    77 /**
       
    78 KIgnoreScreenMode
       
    79 
       
    80 @internalTechnology
       
    81 */
       
    82 const TInt KIgnoreScreenMode=-1;
       
    83 
       
    84 
    59 
    85 _LIT(KDefaultAppIconMbm,"Z:\\Resource\\Apps\\default_app_icon.mbm");
    60 _LIT(KDefaultAppIconMbm,"Z:\\Resource\\Apps\\default_app_icon.mbm");
    86 _LIT(KLitPathForUntrustedRegistrationResourceFiles, "?:\\private\\10003a3f\\import\\apps\\*");
    61 _LIT(KLitPathForUntrustedRegistrationResourceFiles, "?:\\private\\10003a3f\\import\\apps\\*");
    87 
    62 
    88 
    63 
    89 class CApaAppEntry : public CBase
       
    90 /**
       
    91 Utility class with smaller RAM footprint than TApaAppEntry
       
    92 
       
    93 @internalComponent
       
    94 */
       
    95 	{
       
    96 public:
       
    97 	static CApaAppEntry* NewL(const TApaAppEntry& aAppEntry);
       
    98 	~CApaAppEntry();
       
    99 	void Get(TApaAppEntry& aAppEntry) const;
       
   100 private:
       
   101 	CApaAppEntry(const TUidType& aUidType);
       
   102 	void ConstructL(const TDesC& aFileName);
       
   103 private:
       
   104 	TUidType iUidType;
       
   105 	HBufC* iFullName;
       
   106 	};
       
   107 
       
   108 class CApaAppData : public CBase
       
   109 /** Represents the data associated with a CApaApplication, such as its 
       
   110 caption, capabilities and icons. This should be accessed through the Apparc Server.
       
   111 
       
   112 @internalComponent
       
   113 */
       
   114 	{
       
   115 public:
       
   116 #ifdef SYMBIAN_APPARC_APPINFO_CACHE
       
   117 	IMPORT_C static CApaAppData* NewL(const TApaAppEntry& aAppEntry, RFs& aFs);
       
   118 #else
       
   119 	IMPORT_C static CApaAppData* NewL(const TApaAppEntry& aAppEntry, RFs& aFs, const TDesC& aDefaultAppIconFileName);
       
   120 #endif // SYMBIAN_APPARC_APPINFO_CACHE
       
   121 	IMPORT_C ~CApaAppData();
       
   122 	IMPORT_C TApaAppEntry AppEntry() const;
       
   123 	inline TPtrC Caption() const;
       
   124 	inline TPtrC ShortCaption() const;
       
   125 	IMPORT_C CApaMaskedBitmap* Icon(TInt aIconIndex) const;
       
   126 	IMPORT_C void Capability(TDes8& aCapabilityBuf)const;
       
   127 	inline TBool IsPresent() const;
       
   128 	// ER5
       
   129 	IMPORT_C TDataTypePriority DataType(const TDataType& aDataType) const;
       
   130 	// ER6
       
   131 	IMPORT_C CApaMaskedBitmap* Icon(TSize aSize) const;
       
   132 	IMPORT_C CArrayFixFlat<TSize>* IconSizesL() const;
       
   133 	// ER6.1
       
   134 	IMPORT_C CArrayPtrFlat<CApaAppViewData>* Views() const;
       
   135 	IMPORT_C CDesCArray* OwnedFiles() const;
       
   136 	IMPORT_C TBool CanUseScreenMode(TInt aScreenMode);
       
   137 	// 7.0s
       
   138 	IMPORT_C void GetIconInfo(TInt& aIconCount, TInt& aDefaultIconsUsed) const;
       
   139 	// 8.1
       
   140 	IMPORT_C TUint DefaultScreenNumber() const;
       
   141 	IMPORT_C TBool RegistrationFileUsed() const;
       
   142 	IMPORT_C TPtrC IconFileName() const;
       
   143 	IMPORT_C TBool NonMbmIconFile() const;
       
   144 
       
   145 	// 9.0
       
   146 	IMPORT_C TBool ImplementsService(TUid aServiceUid) const;
       
   147 	TInt ImplementsServiceWithDataType(TUid aServiceUid, const TDataType& aDataType) const;
       
   148 
       
   149 	// 9.1
       
   150 	IMPORT_C TLanguage ApplicationLanguage() const;
       
   151 	IMPORT_C TPtrC RegistrationFileName() const;
       
   152 	IMPORT_C TPtrC8 OpaqueData() const;
       
   153 	IMPORT_C TUid NonNativeApplicationType() const;
       
   154 	IMPORT_C TPtrC LocalisableResourceFileName() const;
       
   155 	IMPORT_C void SetShortCaptionL(const TDesC& aShortCaption);
       
   156 	IMPORT_C TBool IsPending()const;
       
   157 	
       
   158 	// Icon/caption overrides
       
   159 	IMPORT_C void SetCaptionL(const TDesC& aCaption);
       
   160 	IMPORT_C void SetIconsL(const TDesC& aFileName, TInt aNumIcons);
       
   161 	
       
   162 #ifdef SYMBIAN_APPARC_APPINFO_CACHE
       
   163 	void ExternalizeL(RWriteStream& aWriteStream) const;	
       
   164 	void LoadIconsL();
       
   165 	TBool MbmIconsRequireLoading() const;
       
   166 	inline CApaAppData* Next() const;
       
   167 #endif // SYMBIAN_APPARC_APPINFO_CACHE
       
   168 
       
   169 private:
       
   170 #ifdef SYMBIAN_APPARC_APPINFO_CACHE
       
   171 	CApaAppData(RFs& aFs);
       
   172 	TBool Update();
       
   173 	void SetAppPending();
       
   174 
       
   175 	void ConstructL(const TApaAppEntry& aAppEntry);
       
   176 	TInt StoreApplicationInformation();
       
   177 #else
       
   178 	CApaAppData(RFs& aFs);
       
   179 	TBool Update(const TDesC& aDefaultAppIconFileName);	
       
   180 	void ConstructL(const TApaAppEntry& aAppEntry, const TDesC& aDefaultAppIconFileName);
       
   181 	TInt StoreApplicationInformation(const TDesC& aDefaultAppIconFileName);
       
   182 #endif // SYMBIAN_APPARC_APPINFO_CACHE
       
   183 	void UpdateServiceArray(CArrayFixFlat<TApaAppServiceInfo>* aNewServiceArray);
       
   184 	TDataTypePriority DataType(const TDataType& aDataType, const CArrayFixFlat<TDataTypeWithPriority>& aDataTypeArray) const;
       
   185 #ifdef SYMBIAN_APPARC_APPINFO_CACHE
       
   186 	void InternalizeL(RReadStream& aReadStream);
       
   187 	TBool ViewMbmIconsRequireLoading() const;
       
   188 #endif // SYMBIAN_APPARC_APPINFO_CACHE
       
   189 private:
       
   190 	enum { ENotPresent, ENotPresentPendingUpdate, EPresentPendingUpdate, EIsPresent, ESuperseded };
       
   191 private:
       
   192 	CApaAppIconArray* iIcons;
       
   193 	HBufC* iCaption;
       
   194 	HBufC* iShortCaption;
       
   195 	HBufC* iFullName; // filename of application binary
       
   196 	TInt iIsPresent; // uses enum
       
   197 	TUidType iUidType;
       
   198 	CApaAppData* iNext;
       
   199 	TApaAppCapabilityBuf iCapabilityBuf;
       
   200 	CApaAppEntry* iSuccessor;
       
   201 	TTime iTimeStamp;
       
   202 	CArrayPtrFlat<CApaAppViewData>* iViewDataArray;
       
   203 	CDesCArray* iOwnedFileArray;
       
   204  	RFs& iFs;
       
   205  	HBufC* iRegistrationFile;
       
   206  	TUint iDefaultScreenNumber;
       
   207  	HBufC* iIconFileName;
       
   208  	TBool iNonMbmIconFile;
       
   209  	HBufC* iLocalisableResourceFileName;
       
   210  	TTime iLocalisableResourceFileTimeStamp;
       
   211 	TTime iIconFileTimeStamp;
       
   212  	TLanguage iApplicationLanguage;
       
   213  	CArrayFixFlat<TApaAppServiceInfo>* iServiceArray;
       
   214  	TInt iIndexOfFirstOpenService;
       
   215 	TUid iNonNativeApplicationType;
       
   216 	HBufC8* iOpaqueData;
       
   217 #ifdef SYMBIAN_APPARC_APPINFO_CACHE
       
   218  	TInt iNumOfAppIcons;
       
   219  	TInt iNumOfAppIconsFromResourceFile;
       
   220  	HBufC* iIconFileNameFromResourceFile; // Icon file name as found in the localisable resource file
       
   221  	TBool iNonMbmIconFileFromResourceFile; // A Flag that tells whether the icon in resource file is non MBM file format
       
   222  	TTime iIconFileTimeStampFromResourceFile;
       
   223 	HBufC* iShortCaptionFromResourceFile;	// Short Caption as found in the localisable resource file
       
   224 	HBufC* iCaptionFromResourceFile;		// Caption as found in the localisable resource file
       
   225 	CApaIconLoader* iIconLoader;
       
   226 #endif // SYMBIAN_APPARC_APPINFO_CACHE
       
   227 
       
   228 private:
       
   229 	friend class CApaAppList;
       
   230 	};
       
   231 
       
   232 class CApaAppViewData : public CBase
       
   233 /**
       
   234 The CApaAppViewData class represents the data associated with an application view.
       
   235 
       
   236 @internalComponent
       
   237 */
       
   238 	{
       
   239 public:
       
   240 	IMPORT_C TUid Uid() const;
       
   241 	inline TPtrC Caption() const;
       
   242 	IMPORT_C CApaMaskedBitmap* Icon(const TSize& aSize) const;
       
   243 	IMPORT_C CArrayFixFlat<TSize>* IconSizesL() const;
       
   244 	IMPORT_C TInt ScreenMode() const;
       
   245 	IMPORT_C TPtrC IconFileName() const;
       
   246 	IMPORT_C TBool NonMbmIconFile() const;
       
   247 public:
       
   248 	~CApaAppViewData();
       
   249 	static CApaAppViewData* NewLC();
       
   250 	void SetUid(TUid aUid);
       
   251 	void SetCaptionL(const TDesC& aCaption);
       
   252 	void SetIconArray(CApaAppIconArray* aIcons);
       
   253 	void SetScreenMode(TInt aScreenMode);
       
   254 	void SetIconFileNameL(const TDesC& aFileName);
       
   255 	void SetNonMbmIconFile(TBool aNonMbmIconFile);
       
   256 #ifdef SYMBIAN_APPARC_APPINFO_CACHE
       
   257 	void SetNumOfViewIcons(TInt aNumOfViewIcons);
       
   258 #endif // SYMBIAN_APPARC_APPINFO_CACHE	
       
   259 private:
       
   260 	CApaAppViewData();
       
   261 	void ConstructL();
       
   262 private:
       
   263 	CApaAppIconArray* iIcons;
       
   264 	HBufC* iCaption;
       
   265 	TUid iUid;
       
   266 	TInt iScreenMode;
       
   267 	HBufC* iIconFileName;
       
   268 	TBool iNonMbmIconFile;
       
   269 #ifdef SYMBIAN_APPARC_APPINFO_CACHE
       
   270 	TInt iNumOfViewIcons;
       
   271 #endif // SYMBIAN_APPARC_APPINFO_CACHE
       
   272 	friend class CApaAppData;
       
   273 	};
       
   274 
       
   275 
       
   276 class MApaAppListObserver
       
   277 /**
       
   278  The MApaAppListObserver interface allows a class to be informed when a CApaAppList is 
       
   279  updated.
       
   280 
       
   281  @internalComponent
       
   282 */
       
   283 	{
       
   284 public:
       
   285 	virtual void NotifyUpdate(TInt aReason)=0;
       
   286 	virtual void InitialListPopulationComplete()=0;
       
   287 	virtual void NotifyScanComplete()=0;
       
   288  	};
       
   289 
       
   290 class CApaAppList : public CBase
       
   291 /**
       
   292 The CApaAppList class provides a list of all available applications present on a device.
       
   293 Its functionality should be accessed through the Apparc Server.
       
   294 
       
   295 @internalComponent
       
   296 */
       
   297 	{
       
   298 public: 
       
   299 	IMPORT_C static CApaAppList* NewL(RFs& aFs,CApaAppRegFinder* aAppRegFinder, TBool aLoadMbmIconsOnDemand, TInt aTimeoutDelay = 50000); // takes ownership of aAppRegFinder
       
   300 public:
       
   301 	IMPORT_C void PurgeL();
       
   302 	inline void Purge();
       
   303 	IMPORT_C TInt Count() const;
       
   304 	IMPORT_C CApaAppData* FirstApp() const;
       
   305 	IMPORT_C CApaAppData* FirstApp(TInt aScreenMode) const; 
       
   306 	IMPORT_C CApaAppData* NextApp(const CApaAppData* aApp) const;
       
   307 	IMPORT_C CApaAppData* NextApp(const CApaAppData* aApp, TInt aScreenMode) const;
       
   308 	IMPORT_C CApaAppData* AppDataByUid(TUid aAppUid) const;
       
   309 	IMPORT_C void StopScan(TBool aNNAInstall = EFalse);
       
   310 	IMPORT_C void RestartScanL();
       
   311 	IMPORT_C TBool AppListUpdatePending();
       
   312 #ifndef SYMBIAN_APPARC_APPINFO_CACHE
       
   313 	IMPORT_C TInt UpdateCounter() const;
       
   314 #endif // SYMBIAN_APPARC_APPINFO_CACHE
       
   315 	// ER5
       
   316 	IMPORT_C TUid PreferredDataHandlerL(const TDataType& aDataType) const;
       
   317 	IMPORT_C void StartIdleUpdateL();
       
   318 	IMPORT_C void StartIdleUpdateL(MApaAppListObserver* aObserver);
       
   319 	IMPORT_C void InitListL(MApaAppListObserver* aObserver);
       
   320 	IMPORT_C TBool IsIdleUpdateComplete() const;
       
   321 	//
       
   322 	IMPORT_C TBool IsFirstScanComplete() const;
       
   323 	IMPORT_C TBool AppScanInProgress() const;
       
   324 	IMPORT_C CBufFlat* ServiceArrayBufferL(TUid aAppUid) const;
       
   325 	IMPORT_C CBufFlat* ServiceImplArrayBufferL(TUid aServiceUid) const;
       
   326 	IMPORT_C CBufFlat* ServiceImplArrayBufferL(TUid aServiceUid, const TDataType& aDataType) const;	
       
   327 	IMPORT_C CBufFlat* ServiceUidBufferL(TUid aAppUid) const;
       
   328 	IMPORT_C CBufFlat* ServiceOpaqueDataBufferL(TUid aAppUid, TUid aServiceUid) const;
       
   329 	IMPORT_C CApaAppData* FindAndAddSpecificAppL(CApaAppRegFinder* aFinder, TUid aAppUid);
       
   330 	IMPORT_C TUid PreferredDataHandlerL(const TDataType& aDataType, const TUid* aServiceUid, 
       
   331 		TInt& aPriority) const;
       
   332 	IMPORT_C ~CApaAppList();
       
   333 	// 9.1
       
   334 	IMPORT_C CApaAppData* AppDataByFileName(const TDesC& aFullFileName) const;
       
   335 	/*IMPORT_C*/ RFs& ShareProtectedFileServer();
       
   336 	IMPORT_C void AddForcedRegistrationL(HBufC* aRegistrationFile);
       
   337 	IMPORT_C void ResetForcedRegistrations();
       
   338 	IMPORT_C static TInt CompareStrings(const HBufC& aFirst, const HBufC& aSecond);
       
   339 	IMPORT_C TBool IsLanguageChangePending() const;
       
   340 	IMPORT_C static CApaAppList* Self();
       
   341     IMPORT_C CArrayFixFlat<TUid>* UninstalledAppArray();
       
   342 	void AcquireDefaultIconArrayL() const;
       
   343 	const CApaAppIconArray& DefaultIconArray() const;
       
   344 	void ReleaseDefaultIconArray() const;
       
   345 #ifdef SYMBIAN_APPARC_APPINFO_CACHE
       
   346 	void StoreL();
       
   347 	void NotifyObserver();
       
   348 	void DeleteAppListStorer();
       
   349 	void DeleteAppIconLoader();
       
   350 	void InitiateStoringOfAppList();
       
   351 #endif // SYMBIAN_APPARC_APPINFO_CACHE
       
   352 private:
       
   353 	enum
       
   354 		{
       
   355 		EFirstScanComplete = 0x01
       
   356 #ifdef SYMBIAN_APPARC_APPINFO_CACHE
       
   357 		,EAppListHasChanged = 0x02,	// This flag is used to check if the applist has really changed after a re-scan/update scan.
       
   358 		ENotifyUpdateOnFirstScanComplete = 0x04	// This flag is used to notify clients for applist update on first boot when AppsList.Bin is used.
       
   359 #endif // SYMBIAN_APPARC_APPINFO_CACHE
       
   360 		,ELangChangePending = 0x08 // This flag is used to check if applist update is in progress on language change event.
       
   361 		};
       
   362 
       
   363 #ifndef SYMBIAN_APPARC_APPINFO_CACHE		
       
   364 	enum
       
   365 		{
       
   366 		EFirstStageScan=0x01,
       
   367 		EScanFinished=0x02,
       
   368 		};
       
   369 #endif // SYMBIAN_APPARC_APPINFO_CACHE
       
   370 
       
   371 private:
       
   372 	CApaAppList(RFs& aFs, CApaAppRegFinder* aAppRegFinder, TBool aLoadMbmIconsOnDemand, TInt aIdlePeriodicDelay);
       
   373 	void UpdateNextAppL(const TApaAppEntry& aAppEntry,TBool& aHasChanged);
       
   374 	void AddToList( CApaAppData* aAppData );
       
   375 	static void SetPending(CApaAppData* aAppData);
       
   376 	static void SetNotFound(CApaAppData* aAppData, TBool& aHasChanged);
       
   377 	static TInt IdleUpdateCallbackL(TAny* aObject);
       
   378 	TInt IdleUpdateL();
       
   379 	void ScanComplete();
       
   380 	void UndoSetPending(CApaAppData* aAppData);
       
   381 
       
   382 #ifdef SYMBIAN_APPARC_APPINFO_CACHE
       
   383 	void StopIdler();
       
   384 	void DeleteAppData();
       
   385 #else	
       
   386 	void StopIdlerL();
       
   387 #endif // SYMBIAN_APPARC_APPINFO_CACHE
       
   388 	CArrayFixFlat<TDataTypeWithPriority>* DataTypeArrayDeepCopyLC(const CArrayFixFlat<TDataTypeWithPriority>& aOriginal) const;
       
   389 	CApaAppIconArray* LoadDefaultIconsL() const;
       
   390 	void UpdateDefaultIconsL();
       
   391 #ifdef SYMBIAN_APPARC_APPINFO_CACHE
       
   392 	void StartIconLoadingL();
       
   393 	void DeleteAppsListBackUpAndTempFiles();
       
   394 	void ScanRemovableDrivesAndUpdateL();
       
   395 	void CreateDefaultAppIconFileNameL();
       
   396 #endif // SYMBIAN_APPARC_APPINFO_CACHE
       
   397 
       
   398 private: 
       
   399 	// Persistence Layer
       
   400 	void RestoreL();
       
   401 	void ConstructL();
       
   402 #ifndef SYMBIAN_APPARC_APPINFO_CACHE
       
   403 	void StoreL();
       
   404 	void StoreEntryL(RFileWriteStream& theWriteStream,CApaAppData* aApp);
       
   405 	void DoStoreL(RFileWriteStream& aWriteStream);
       
   406 #endif // SYMBIAN_APPARC_APPINFO_CACHE
       
   407 
       
   408 	void GetAppsListCachePathL();
       
   409 #ifdef SYMBIAN_APPARC_APPINFO_CACHE
       
   410 	NONSHARABLE_CLASS(CApaIdleIconLoader) : public CActive
       
   411 		{
       
   412 	/**
       
   413 	Utility class used to Load Icons once applist is populated
       
   414 	@internalComponent
       
   415 	*/	
       
   416 	public:
       
   417 		CApaIdleIconLoader(CApaAppData* aFirstAppData, RFs& aFs, CApaAppList& aAppList);
       
   418 		~CApaIdleIconLoader();
       
   419 		void Start();
       
   420 
       
   421 	private:	// from CActive
       
   422 		void RunL();
       
   423 		void DoCancel();
       
   424 		TInt RunError(TInt aError);
       
   425 
       
   426 	private:
       
   427 		CApaAppData* iCurrentAppData;
       
   428 		RFs& iFs;
       
   429 		CApaAppList& iAppList;
       
   430 		};
       
   431 
       
   432 	NONSHARABLE_CLASS(CApaAppListStorer) : public CActive
       
   433 		{
       
   434 	/**
       
   435 	Utility class used to externalize applist to file
       
   436 	@internalComponent
       
   437 	*/	
       
   438 	public:
       
   439 		static CApaAppListStorer* NewL(CApaAppData* aFirstAppData, RFs& aFs, CApaAppList& aAppList);
       
   440 		~CApaAppListStorer();
       
   441 		void StartL(const TTimeIntervalMicroSeconds32& aDelay);
       
   442 
       
   443 	private:
       
   444 		CApaAppListStorer(CApaAppData* aFirstAppData, RFs& aFs, CApaAppList& aAppList);
       
   445 		static void StoreEntryL(RWriteStream& aWriteStream, const CApaAppData& aApp);
       
   446 		void ConstructL();
       
   447 
       
   448 	private:	// from CActive
       
   449 		void RunL();
       
   450 		void DoCancel();
       
   451 		TInt RunError(TInt aError);
       
   452 
       
   453 	private:
       
   454 		CApaAppData* iCurrentAppData;
       
   455 		TFileName iTempFilename;
       
   456 		RFileWriteStream iWriteStream;
       
   457 		RTimer iTimer;
       
   458 		RFs& iFs;
       
   459 		CApaAppList& iAppList;
       
   460 		};
       
   461 #endif // SYMBIAN_APPARC_APPINFO_CACHE
       
   462 	
       
   463 private:
       
   464 	RFs& iFs;
       
   465 	CApaAppData* iAppData; // linked list of apps
       
   466 	CPeriodic* iAppIdler;
       
   467 	MApaAppListObserver* iObserver;
       
   468 	CApaAppData* iValidFirstAppData; //First valid app data in linked list!
       
   469 	TInt iFlags;
       
   470 	CApaAppRegFinder* iAppRegFinder;
       
   471 	TInt iIdlePeriodicDelay; 	// idle timeout periodic delay
       
   472 	RFs iFsShareProtected;
       
   473 	mutable CApaAppIconArray* iDefaultIconArray;
       
   474 	mutable TInt iDefaultIconUsageCount;
       
   475 	RPointerArray<HBufC> iForcedRegistrations;
       
   476 	class CApaLangChangeMonitor; //inner class of CApaAppList.
       
   477 	CApaLangChangeMonitor* iAppLangMonitor; // Active Object used for language change monitoring.		
       
   478 
       
   479 	RBuf iAppsListCacheFileName;
       
   480 	RBuf iAppsListCacheBackUpFileName;
       
   481 	RBuf iAppsListCachePath;
       
   482 
       
   483 #ifdef SYMBIAN_APPARC_APPINFO_CACHE
       
   484 	HBufC* iDefaultAppIconMbmFileName; // This member data lives only during the scan
       
   485 	CApaAppListStorer* iAppListStorer;	//Active Object used for writing applist to file.
       
   486 	CApaIdleIconLoader* iAppIconLoader;	//Active Object used for icon handling
       
   487 #else
       
   488 	TInt iScanStage;
       
   489 	TInt iUpdateCounter;
       
   490 	TApaAppEntry iCurrentApp;
       
   491 	TInt iOldUpdateCounter;
       
   492 	HBufC* iDefaultAppIcon; // This member data lives only during the scan
       
   493 #endif // SYMBIAN_APPARC_APPINFO_CACHE
       
   494 	TBool iLoadMbmIconsOnDemand;
       
   495 	TBool iNNAInstallation;
       
   496     CArrayFixFlat<TUid>* iUninstalledApps; 
       
   497 
       
   498 private:
       
   499 	friend class CApaLangChangeMonitor;
       
   500 	};
       
   501 
       
   502 //
       
   503 // inlines
       
   504 //
       
   505 
       
   506 inline TPtrC CApaAppViewData::Caption() const
       
   507 	{ return *iCaption; }
       
   508 
       
   509 inline TPtrC CApaAppData::Caption() const
       
   510 /** Gets the application's caption.
       
   511 
       
   512 @return The application's caption. */
       
   513 	{ return *iCaption; }
       
   514 
       
   515 inline TPtrC CApaAppData::ShortCaption() const
       
   516 /** Gets the application's short caption.
       
   517 
       
   518 @return The application's short caption. */
       
   519 	{ return *iShortCaption; }
       
   520 
       
   521 inline TBool CApaAppData::IsPresent() const
       
   522 /** Tests whether the application is present or not on the device.
       
   523 
       
   524 @return True if application exists, else false. */
       
   525 	{ return iIsPresent; }
       
   526 
       
   527 #ifdef SYMBIAN_APPARC_APPINFO_CACHE
       
   528 inline CApaAppData* CApaAppData::Next() const
       
   529 /** Gets the Next Appdata in the list
       
   530 
       
   531 @return iNext */
       
   532 	{ return iNext; }
       
   533 #endif // SYMBIAN_APPARC_APPINFO_CACHE
       
   534 
       
   535 /**
       
   536  * Use PurgeL.
       
   537  *
       
   538  * @deprecated
       
   539  */
       
   540 inline void CApaAppList::Purge()
       
   541 	{	TRAP_IGNORE(PurgeL());	}
       
   542 
       
   543 #endif //__APGAPLST_H__
    64 #endif //__APGAPLST_H__