25 #include <e32base.h> |
25 #include <e32base.h> |
26 #include "iaupdateuidefines.h" |
26 #include "iaupdateuidefines.h" |
27 #include "iaupdatecontroller.h" |
27 #include "iaupdatecontroller.h" |
28 #include "iaupdatecontrollerobserver.h" |
28 #include "iaupdatecontrollerobserver.h" |
29 #include "iaupdatenodeobserver.h" |
29 #include "iaupdatenodeobserver.h" |
30 #include "iaupdatewaitdialogobserver.h" |
|
31 #include "iaupdatedialogobserver.h" |
30 #include "iaupdatedialogobserver.h" |
32 #include "iaupdatestarterobserver.h" |
31 #include "iaupdatestarterobserver.h" |
33 #include "iaupdateroaminghandlerobserver.h" |
32 #include "iaupdateroaminghandlerobserver.h" |
34 #include "iaupdaterefreshobserver.h" |
33 #include "iaupdaterefreshobserver.h" |
35 #include "iaupdateresultsinfo.h" |
34 #include "iaupdateresultsinfo.h" |
36 #include "iaupdateversion.h" |
35 #include "iaupdateversion.h" |
37 #include "iaupdateanynode.h" |
36 #include "iaupdateanynode.h" |
38 |
37 |
39 // FORWARD DECLARATIONS |
38 // FORWARD DECLARATIONS |
40 class CIAUpdateWaitDialog; |
|
41 class CIAUpdateProgressDialog; |
|
42 class CIAUpdateNodeFilter; |
39 class CIAUpdateNodeFilter; |
43 class CIAUpdateStarter; |
40 class CIAUpdateStarter; |
44 class CIAUpdateControllerFile; |
41 class CIAUpdateControllerFile; |
45 class CIAUpdateUiConfigData; |
42 class CIAUpdateUiConfigData; |
46 class CIAUpdateRoamingHandler; |
43 class CIAUpdateRoamingHandler; |
47 class CIAUpdateRefreshHandler; |
44 class CIAUpdateRefreshHandler; |
48 class MIAUpdateUiControllerObserver; |
45 class MIAUpdateUiControllerObserver; |
49 class MIAUpdateHistory; |
46 class MIAUpdateHistory; |
50 class MIAUpdateFwNode; |
47 class MIAUpdateFwNode; |
51 class IAUpdateWaitDialog; |
|
52 class IAUpdateDialogUtil; |
48 class IAUpdateDialogUtil; |
53 |
49 |
54 class QString; |
50 class QString; |
55 class CIAUpdateNodeId; |
51 class CIAUpdateNodeId; |
56 class CEikonEnv; |
52 class CEikonEnv; |
64 */ |
60 */ |
65 class CIAUpdateUiController : |
61 class CIAUpdateUiController : |
66 public CBase, |
62 public CBase, |
67 public MIAUpdateControllerObserver, |
63 public MIAUpdateControllerObserver, |
68 public MIAUpdateNodeObserver, |
64 public MIAUpdateNodeObserver, |
69 public MIAUpdateWaitDialogObserver, |
|
70 public MIAUpdateStarterObserver, |
65 public MIAUpdateStarterObserver, |
71 public MIAUpdateRoamingHandlerObserver, |
66 public MIAUpdateRoamingHandlerObserver, |
72 public MIAUpdateRefreshObserver, |
67 public MIAUpdateRefreshObserver, |
73 public IAUpdateDialogObserver |
68 public IAUpdateDialogObserver |
74 { |
69 { |
331 |
332 |
332 /** |
333 /** |
333 * Called when roaming handler is prepared |
334 * Called when roaming handler is prepared |
334 */ |
335 */ |
335 void RoamingHandlerPrepared(); |
336 void RoamingHandlerPrepared(); |
336 |
337 |
337 |
|
338 private: // From MIAUpdateWaitDialogObserver |
|
339 |
|
340 /** |
|
341 * This is called when the dialog is closed. |
|
342 */ |
|
343 void HandleWaitDialogCancel(); |
|
344 |
338 |
345 private: // From IAUpdateDialogObserver |
339 private: // From IAUpdateDialogObserver |
346 |
340 |
347 void dialogFinished(HbAction *action); |
341 void dialogFinished(HbAction *action); |
348 |
342 |
426 * Callback of CIdle, calls CheckUpdates() |
420 * Callback of CIdle, calls CheckUpdates() |
427 * |
421 * |
428 * @param aPtr Pointer to this instance |
422 * @param aPtr Pointer to this instance |
429 */ |
423 */ |
430 static TInt CheckUpdatesDeferredCallbackL( TAny* aPtr ); |
424 static TInt CheckUpdatesDeferredCallbackL( TAny* aPtr ); |
431 |
425 |
432 /** |
|
433 * Shows waiting/progress dialog during update process. |
|
434 * |
|
435 * @param aTextResourceId Resource id of text (Downloading or Installing) |
|
436 * @param aName Name of update |
|
437 * @param aNumber Counter of current update |
|
438 * @param aTotalCount Total count of updates to be updated |
|
439 */ |
|
440 void ShowUpdatingDialogL( TInt aTextResourceId, |
|
441 const TDesC& aName, |
|
442 TInt aNumber, |
|
443 TInt aTotalCount ); |
|
444 |
|
445 /** |
|
446 * Shows waiting dialog during update process. |
|
447 * |
|
448 * @param aDisplayString A string to be displayed |
|
449 * @param aVisibilityDelayOff ETrue if visibility delay is off |
|
450 */ |
|
451 void ShowWaitDialogL( const QString& aDisplayString, |
|
452 TBool aVisibilityDelayOff ); |
|
453 |
|
454 /** |
|
455 * Shows progress dialog during update process. |
|
456 * |
|
457 * @param aDisplayString A string to be displayed |
|
458 * @param aVisibilityDelayOff ETrue if visibility delay is off |
|
459 */ |
|
460 void ShowProgressDialogL( const TDesC& aDisplayString, |
|
461 TBool aVisibilityDelayOff ); |
|
462 |
|
463 /** |
|
464 * Removes all possible existing update flow dialogs. |
|
465 * This method is a general way to handle removal of |
|
466 * wait or progress dialogs. |
|
467 */ |
|
468 void RemoveUpdatingDialogsL(); |
|
469 |
|
470 /** |
|
471 * Removes waiting dialog. |
|
472 */ |
|
473 void RemoveWaitDialogL(); |
|
474 |
|
475 /** |
|
476 * Removes progress dialog. |
|
477 */ |
|
478 void RemoveProgressDialogL(); |
|
479 |
|
480 /** |
426 /** |
481 * Checks if refreshing of update list allowed from a network |
427 * Checks if refreshing of update list allowed from a network |
482 * @return ETrue if network refresh allowed |
428 * @return ETrue if network refresh allowed |
483 */ |
429 */ |
484 TBool AllowNetworkRefreshL(); |
430 TBool AllowNetworkRefreshL(); |
518 * Updates self update item error codes into the purchase history |
464 * Updates self update item error codes into the purchase history |
519 * after self updater could not do its job. |
465 * after self updater could not do its job. |
520 * @param aErrorCode Error code that self updater has failed with. |
466 * @param aErrorCode Error code that self updater has failed with. |
521 */ |
467 */ |
522 void UpdateFailedSelfUpdaterInfoToPurchaseHistoryL( TInt aErrorCode ); |
468 void UpdateFailedSelfUpdaterInfoToPurchaseHistoryL( TInt aErrorCode ); |
523 |
469 |
524 /** |
|
525 * Handles user cancel |
|
526 */ |
|
527 void HandleUserCancelL(); |
|
528 |
|
529 /** |
470 /** |
530 * @return TBool ETrue if IAD has been started right after |
471 * @return TBool ETrue if IAD has been started right after |
531 * the self update. In other words, self update related data |
472 * the self update. In other words, self update related data |
532 * has not been handled yet. Else EFalse. |
473 * has not been handled yet. Else EFalse. |
533 */ |
474 */ |
584 RPointerArray<CIAUpdateNodeId> iPreviousSelections; |
525 RPointerArray<CIAUpdateNodeId> iPreviousSelections; |
585 |
526 |
586 RPointerArray<MIAUpdateNode> iServicePackNodes; |
527 RPointerArray<MIAUpdateNode> iServicePackNodes; |
587 |
528 |
588 IAUpdateDialogUtil *mDialogUtil; |
529 IAUpdateDialogUtil *mDialogUtil; |
589 |
530 |
590 IAUpdateWaitDialog *mWaitDialog; |
|
591 |
|
592 CIAUpdateProgressDialog* iProgressDialog; |
|
593 |
|
594 CIAUpdateStarter* iStarter; |
531 CIAUpdateStarter* iStarter; |
595 |
532 |
596 CIAUpdateRoamingHandler* iRoamingHandler; |
533 CIAUpdateRoamingHandler* iRoamingHandler; |
597 |
534 |
598 CIAUpdateRefreshHandler* iRefreshHandler; |
535 CIAUpdateRefreshHandler* iRefreshHandler; |