259 * Launches a global note about completed download(s). |
260 * Launches a global note about completed download(s). |
260 * @param aPart A bundle of IDs identifying the message for which the note is shown. |
261 * @param aPart A bundle of IDs identifying the message for which the note is shown. |
261 * @param aCompletedCount How many attachments were succesfully downloaded. |
262 * @param aCompletedCount How many attachments were succesfully downloaded. |
262 */ |
263 */ |
263 void LaunchDownloadCompleteNoteL( const TPartData& aPart, TInt aCompletedCount ); |
264 void LaunchDownloadCompleteNoteL( const TPartData& aPart, TInt aCompletedCount ); |
264 |
265 |
265 /** |
266 /** |
266 * Notify all the registered observers about a download event. |
267 * Notify all the registered observers about a download event. |
267 */ |
268 */ |
268 void NotifyObserversL( const TFSProgress& aEvent, const TPartData& aPart ); |
269 void NotifyObserversL( const TFSProgress& aEvent, const TPartData& aPart ); |
269 |
270 |
|
271 /** |
|
272 * Notify all the registered observers for a particular message part about a download event. |
|
273 */ |
|
274 void NotifyPartObserversL( const TFSProgress& aEvent, const TPartData& aPart ); |
|
275 |
|
276 /** |
|
277 * Removes deleted observers from the observer array. |
|
278 */ |
|
279 void CleanUpObservers(); |
|
280 |
|
281 /** |
|
282 * Safely removes an entry from the observer array in case notifications |
|
283 * are currently in process. |
|
284 */ |
|
285 void RemoveObserver( TInt aIdx ); |
|
286 |
270 /** |
287 /** |
271 * Updates the entry in iDownloadCountArray according a progress event and gets a copy of |
288 * Updates the entry in iDownloadCountArray according a progress event and gets a copy of |
272 * its data. The original entry may be removed from the array as a result. |
289 * its data. The original entry may be removed from the array as a result. |
273 * @param aCountObject Input/output argument for the count array entry. The entries are matched by the iMessageId. |
290 * @param aCountObject Input/output argument for the count array entry. The entries are matched by the iMessageId. |
274 * @param aEvent The event which causes the entry to be updated. |
291 * @param aEvent The event which causes the entry to be updated. |
322 // array of download observers (all messages) |
339 // array of download observers (all messages) |
323 RPointerArray<MFSEmailDownloadInformationObserver> iAllObserverArray; |
340 RPointerArray<MFSEmailDownloadInformationObserver> iAllObserverArray; |
324 |
341 |
325 // has there been any downloads since program started |
342 // has there been any downloads since program started |
326 TBool iDownloadsStarted; |
343 TBool iDownloadsStarted; |
|
344 |
|
345 // counter indicating how many observer notification operations are |
|
346 // currently in progress |
|
347 TInt iNotificationsInProgress; |
|
348 |
|
349 // have any observers been deleted during notification |
|
350 TBool iObserverDeleted; |
327 }; |
351 }; |
328 |
352 |
329 #endif // FSEMAILDOWNLOADINFORMATIONMEDIATOR_H |
353 #endif // FSEMAILDOWNLOADINFORMATIONMEDIATOR_H |
330 |
354 |
331 // end of file |
355 // end of file |