|
1 /* |
|
2 * Copyright (c) 2007-2008 Nokia Corporation and/or its subsidiary(-ies). |
|
3 * All rights reserved. |
|
4 * This component and the accompanying materials are made available |
|
5 * under the terms of "Eclipse Public License v1.0" |
|
6 * which accompanies this distribution, and is available |
|
7 * at the URL "http://www.eclipse.org/legal/epl-v10.html". |
|
8 * |
|
9 * Initial Contributors: |
|
10 * Nokia Corporation - initial contribution. |
|
11 * |
|
12 * Contributors: |
|
13 * |
|
14 * Description: Declares control class for the application. |
|
15 * |
|
16 */ |
|
17 |
|
18 |
|
19 |
|
20 #ifndef __FREESTYLEMAILUI_FOLDERLISTCONTROL_H_ |
|
21 #define __FREESTYLEMAILUI_FOLDERLISTCONTROL_H_ |
|
22 |
|
23 // SYSTEM INCLUDES |
|
24 //<cmail> |
|
25 #include <alf/alfenv.h> |
|
26 #include <alf/alfcontrol.h> |
|
27 //</cmail> |
|
28 |
|
29 #include "FreestyleEmailUiUtilities.h" |
|
30 |
|
31 // FORWARD DECLARATIONS |
|
32 class CFSEmailUiFolderListVisualiser; |
|
33 |
|
34 class CFSEmailUiFolderListControl : public CAlfControl, |
|
35 public MFSEmailUiGenericTimerCallback |
|
36 { |
|
37 public: |
|
38 |
|
39 /** |
|
40 * Two-phased constructor. |
|
41 * |
|
42 * @param aEnv Reference to the ALF environment. |
|
43 * @param aEnv Pointer to visualiser, ownership not transferred. |
|
44 */ |
|
45 static CFSEmailUiFolderListControl* NewL( CAlfEnv& aEnv, CFSEmailUiFolderListVisualiser& aVisualiser ); |
|
46 |
|
47 /** |
|
48 * Two-phased constructor. |
|
49 * |
|
50 * @param aEnv Reference to the ALF environment. |
|
51 */ |
|
52 static CFSEmailUiFolderListControl* NewLC( CAlfEnv& aEnv, CFSEmailUiFolderListVisualiser& aVisualiser ); |
|
53 |
|
54 /** |
|
55 * Event handling |
|
56 * |
|
57 * @param aEvent Event to be handled |
|
58 * @return ETrue if event was consumed, otherwise EFalse |
|
59 */ |
|
60 TBool OfferEventL( const TAlfEvent& aEvent ); |
|
61 |
|
62 /** |
|
63 * Command handling |
|
64 * |
|
65 * @param aCommand Command to be handled |
|
66 */ |
|
67 void HandleCommandL( TInt aCommand ); |
|
68 |
|
69 /** |
|
70 * Virtual destructor. |
|
71 */ |
|
72 ~CFSEmailUiFolderListControl(); |
|
73 |
|
74 public: // From base class MFSEmailUiGenericTimerCallback |
|
75 /** |
|
76 * Timer callback function. |
|
77 */ |
|
78 void TimerEventL( CFSEmailUiGenericTimer* aTriggeredTimer ); |
|
79 |
|
80 // Only for testing |
|
81 //void StarTestTimer(); |
|
82 private: |
|
83 |
|
84 /** |
|
85 * Constructor. |
|
86 * |
|
87 * @param aEnv Reference to the ALF environment. |
|
88 * @param aVisualiser Reference to visualiser for command handling. |
|
89 */ |
|
90 CFSEmailUiFolderListControl( CFSEmailUiFolderListVisualiser& aVisualiser ); |
|
91 |
|
92 /** |
|
93 * Two-phased constructor. |
|
94 */ |
|
95 void ConstructL(CAlfEnv& aEnv); |
|
96 |
|
97 private: |
|
98 CFSEmailUiFolderListVisualiser& iVisualiser; |
|
99 |
|
100 }; |
|
101 |
|
102 #endif /*__FREESTYLEMAILUI_FOLDERLISTCONTROL_H_*/ |