99 |
92 |
100 @internalComponent |
93 @internalComponent |
101 */ |
94 */ |
102 class CApaAppData : public CBase |
95 class CApaAppData : public CBase |
103 { |
96 { |
104 public: |
97 public: |
105 #ifdef SYMBIAN_UNIVERSAL_INSTALL_FRAMEWORK |
98 IMPORT_C static CApaAppData* NewL(const TApaAppEntry& aAppEntry, RFs& aFs); |
106 IMPORT_C static CApaAppData* NewL(const Usif::CApplicationRegistrationData& aAppInfo, RFs& aFs, const Usif::RSoftwareComponentRegistry& aScrCon); |
|
107 IMPORT_C TBool IsLangChangePending(); |
|
108 #else |
|
109 IMPORT_C static CApaAppData* NewL(const TApaAppEntry& aAppEntry, RFs& aFs); |
|
110 inline TBool IsPresent() const; |
|
111 IMPORT_C TBool RegistrationFileUsed() const; |
|
112 IMPORT_C TPtrC RegistrationFileName() const; |
|
113 IMPORT_C TBool IsPending()const; |
|
114 IMPORT_C TPtrC LocalisableResourceFileName() const; |
|
115 #endif |
|
116 |
|
117 IMPORT_C ~CApaAppData(); |
99 IMPORT_C ~CApaAppData(); |
118 IMPORT_C TApaAppEntry AppEntry() const; |
100 IMPORT_C TApaAppEntry AppEntry() const; |
119 inline TPtrC Caption() const; |
101 inline TPtrC Caption() const; |
120 inline TPtrC ShortCaption() const; |
102 inline TPtrC ShortCaption() const; |
121 IMPORT_C CApaMaskedBitmap* Icon(TInt aIconIndex) const; |
103 IMPORT_C CApaMaskedBitmap* Icon(TInt aIconIndex) const; |
122 IMPORT_C void Capability(TDes8& aCapabilityBuf)const; |
104 IMPORT_C void Capability(TDes8& aCapabilityBuf)const; |
|
105 inline TBool IsPresent() const; |
123 // ER5 |
106 // ER5 |
124 IMPORT_C TDataTypePriority DataType(const TDataType& aDataType) const; |
107 IMPORT_C TDataTypePriority DataType(const TDataType& aDataType) const; |
125 // ER6 |
108 // ER6 |
126 IMPORT_C CApaMaskedBitmap* Icon(TSize aSize) const; |
109 IMPORT_C CApaMaskedBitmap* Icon(TSize aSize) const; |
127 IMPORT_C CArrayFixFlat<TSize>* IconSizesL() const; |
110 IMPORT_C CArrayFixFlat<TSize>* IconSizesL() const; |
131 IMPORT_C TBool CanUseScreenMode(TInt aScreenMode); |
114 IMPORT_C TBool CanUseScreenMode(TInt aScreenMode); |
132 // 7.0s |
115 // 7.0s |
133 IMPORT_C void GetIconInfo(TInt& aIconCount, TInt& aDefaultIconsUsed) const; |
116 IMPORT_C void GetIconInfo(TInt& aIconCount, TInt& aDefaultIconsUsed) const; |
134 // 8.1 |
117 // 8.1 |
135 IMPORT_C TUint DefaultScreenNumber() const; |
118 IMPORT_C TUint DefaultScreenNumber() const; |
|
119 IMPORT_C TBool RegistrationFileUsed() const; |
136 IMPORT_C TPtrC IconFileName() const; |
120 IMPORT_C TPtrC IconFileName() const; |
137 IMPORT_C TBool NonMbmIconFile() const; |
121 IMPORT_C TBool NonMbmIconFile() const; |
|
122 |
138 // 9.0 |
123 // 9.0 |
139 IMPORT_C TBool ImplementsService(TUid aServiceUid) const; |
124 IMPORT_C TBool ImplementsService(TUid aServiceUid) const; |
140 TInt ImplementsServiceWithDataType(TUid aServiceUid, const TDataType& aDataType) const; |
125 TInt ImplementsServiceWithDataType(TUid aServiceUid, const TDataType& aDataType) const; |
141 |
126 |
142 // 9.1 |
127 // 9.1 |
143 IMPORT_C TLanguage ApplicationLanguage() const; |
128 IMPORT_C TLanguage ApplicationLanguage() const; |
|
129 IMPORT_C TPtrC RegistrationFileName() const; |
144 IMPORT_C TPtrC8 OpaqueData() const; |
130 IMPORT_C TPtrC8 OpaqueData() const; |
145 IMPORT_C TUid NonNativeApplicationType() const; |
131 IMPORT_C TUid NonNativeApplicationType() const; |
|
132 IMPORT_C TPtrC LocalisableResourceFileName() const; |
146 IMPORT_C void SetShortCaptionL(const TDesC& aShortCaption); |
133 IMPORT_C void SetShortCaptionL(const TDesC& aShortCaption); |
|
134 IMPORT_C TBool IsPending()const; |
147 // 9.5 |
135 // 9.5 |
148 IMPORT_C void SetCaptionL(const TDesC& aCaption); |
136 IMPORT_C void SetCaptionL(const TDesC& aCaption); |
149 IMPORT_C void SetIconsL(const TDesC& aFileName, TInt aNumIcons); |
137 IMPORT_C void SetIconsL(const TDesC& aFileName, TInt aNumIcons); |
150 |
138 |
151 void ExternalizeL(RWriteStream& aWriteStream) const; |
139 void ExternalizeL(RWriteStream& aWriteStream) const; |
152 void LoadIconsL(); |
140 void LoadIconsL(); |
153 TBool MbmIconsRequireLoading() const; |
141 TBool MbmIconsRequireLoading() const; |
154 inline CApaAppData* Next() const; |
142 inline CApaAppData* Next() const; |
155 private: |
143 private: |
156 CApaAppData(RFs& aFs); |
144 CApaAppData(RFs& aFs); |
|
145 TBool Update(); |
|
146 void SetAppPending(); |
|
147 |
|
148 void ConstructL(const TApaAppEntry& aAppEntry); |
|
149 TInt ReadApplicationInformationFromResourceFiles(); |
157 void UpdateServiceArray(CArrayFixFlat<TApaAppServiceInfo>* aNewServiceArray); |
150 void UpdateServiceArray(CArrayFixFlat<TApaAppServiceInfo>* aNewServiceArray); |
158 TDataTypePriority DataType(const TDataType& aDataType, const CArrayFixFlat<TDataTypeWithPriority>& aDataTypeArray) const; |
151 TDataTypePriority DataType(const TDataType& aDataType, const CArrayFixFlat<TDataTypeWithPriority>& aDataTypeArray) const; |
159 void InternalizeL(RReadStream& aReadStream); |
152 void InternalizeL(RReadStream& aReadStream); |
160 TBool ViewMbmIconsRequireLoading() const; |
153 TBool ViewMbmIconsRequireLoading() const; |
161 |
|
162 #ifdef SYMBIAN_UNIVERSAL_INSTALL_FRAMEWORK |
|
163 void ConstructL(const Usif::CApplicationRegistrationData& aAppInfo, const Usif::RSoftwareComponentRegistry& aScrCon); |
|
164 TInt ReadApplicationInformationFromSCRL(const Usif::CApplicationRegistrationData& aAppInfo, const Usif::RSoftwareComponentRegistry& aScrCon); |
|
165 #else |
|
166 TBool Update(); |
|
167 void SetAppPending(); |
|
168 void ConstructL(const TApaAppEntry& aAppEntry); |
|
169 TInt ReadApplicationInformationFromResourceFiles(); |
|
170 #endif |
|
171 |
|
172 private: |
154 private: |
173 enum { ENotPresent, ENotPresentPendingUpdate, EPresentPendingUpdate, EIsPresent, ESuperseded }; |
155 enum { ENotPresent, ENotPresentPendingUpdate, EPresentPendingUpdate, EIsPresent, ESuperseded }; |
174 private: |
156 private: |
175 CApaAppIconArray* iIcons; |
157 CApaAppIconArray* iIcons; |
176 HBufC* iCaption; |
158 HBufC* iCaption; |
177 HBufC* iShortCaption; |
159 HBufC* iShortCaption; |
178 HBufC* iFullName; // filename of application binary |
160 HBufC* iFullName; // filename of application binary |
179 TUid iUid; |
161 TInt iIsPresent; // uses enum |
180 TUidType iUidType; |
162 TUidType iUidType; |
181 CApaAppData* iNext; |
163 CApaAppData* iNext; |
182 TApaAppCapabilityBuf iCapabilityBuf; |
164 TApaAppCapabilityBuf iCapabilityBuf; |
183 CApaAppEntry* iSuccessor; |
165 CApaAppEntry* iSuccessor; |
|
166 TTime iTimeStamp; |
184 CArrayPtrFlat<CApaAppViewData>* iViewDataArray; |
167 CArrayPtrFlat<CApaAppViewData>* iViewDataArray; |
185 CDesCArray* iOwnedFileArray; |
168 CDesCArray* iOwnedFileArray; |
186 RFs& iFs; |
169 RFs& iFs; |
|
170 HBufC* iRegistrationFile; |
187 TUint iDefaultScreenNumber; |
171 TUint iDefaultScreenNumber; |
188 HBufC* iIconFileName; |
172 HBufC* iIconFileName; |
189 TBool iNonMbmIconFile; |
173 TBool iNonMbmIconFile; |
|
174 HBufC* iLocalisableResourceFileName; |
|
175 TTime iLocalisableResourceFileTimeStamp; |
|
176 TTime iIconFileTimeStamp; |
190 TLanguage iApplicationLanguage; |
177 TLanguage iApplicationLanguage; |
191 CArrayFixFlat<TApaAppServiceInfo>* iServiceArray; |
178 CArrayFixFlat<TApaAppServiceInfo>* iServiceArray; |
192 TInt iIndexOfFirstOpenService; |
179 TInt iIndexOfFirstOpenService; |
|
180 TUid iNonNativeApplicationType; |
193 HBufC8* iOpaqueData; |
181 HBufC8* iOpaqueData; |
194 TInt iNumOfAppIcons; |
182 TInt iNumOfAppIcons; |
195 TInt iNumOfAppIconsFromResourceFile; |
183 TInt iNumOfAppIconsFromResourceFile; |
196 HBufC* iIconFileNameFromResourceFile; // Icon file name as found in the localisable resource file |
184 HBufC* iIconFileNameFromResourceFile; // Icon file name as found in the localisable resource file |
197 TBool iNonMbmIconFileFromResourceFile; // A Flag that tells whether the icon in resource file is non MBM file format |
185 TBool iNonMbmIconFileFromResourceFile; // A Flag that tells whether the icon in resource file is non MBM file format |
|
186 TTime iIconFileTimeStampFromResourceFile; |
198 HBufC* iShortCaptionFromResourceFile; // Short Caption as found in the localisable resource file |
187 HBufC* iShortCaptionFromResourceFile; // Short Caption as found in the localisable resource file |
199 HBufC* iCaptionFromResourceFile; // Caption as found in the localisable resource file |
188 HBufC* iCaptionFromResourceFile; // Caption as found in the localisable resource file |
200 CApaIconLoader* iIconLoader; |
189 CApaIconLoader* iIconLoader; |
201 #ifndef SYMBIAN_UNIVERSAL_INSTALL_FRAMEWORK |
|
202 TInt iIsPresent; // uses enum |
|
203 TTime iTimeStamp; |
|
204 HBufC* iRegistrationFile; |
|
205 HBufC* iLocalisableResourceFileName; |
|
206 TTime iLocalisableResourceFileTimeStamp; |
|
207 TTime iIconFileTimeStamp; |
|
208 TUid iNonNativeApplicationType; |
|
209 TTime iIconFileTimeStampFromResourceFile; |
|
210 #endif |
|
211 |
|
212 #ifdef SYMBIAN_UNIVERSAL_INSTALL_FRAMEWORK |
|
213 TBool iIsLangChangePending; |
|
214 #endif |
|
215 |
|
216 private: |
190 private: |
217 friend class CApaAppList; |
191 friend class CApaAppList; |
218 }; |
192 }; |
219 |
193 |
220 /** |
194 /** |