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: Class header for CWsfDetailsView |
|
15 * |
|
16 */ |
|
17 |
|
18 #ifndef C_WSFDETAILSVIEW_H |
|
19 #define C_WSFDETAILSVIEW_H |
|
20 |
|
21 // EXTERNAL INCLUDES |
|
22 #include <aknview.h> |
|
23 #include <aknlists.h> |
|
24 |
|
25 // INTERNAL INCLUDES |
|
26 #include "wsfdetailsviewcontrollerif.h" |
|
27 #include "wsfdetailsviewcontroller.h" |
|
28 |
|
29 // FORWARD DECLARATIONS |
|
30 class CWsfDetailsContainer; |
|
31 class MDetailsViewPartner; |
|
32 class CWsfDetailsViewModel; |
|
33 class TWsfDetailsViewController; |
|
34 |
|
35 // CLASS DECLARATION |
|
36 /** |
|
37 * CWsfDetailsView view class. |
|
38 */ |
|
39 class CWsfDetailsView : public CAknView, |
|
40 public MEikListBoxObserver |
|
41 { |
|
42 |
|
43 public: |
|
44 |
|
45 // Constructors and destructor |
|
46 /** |
|
47 * Two-phased constructor |
|
48 * @since S60 5.0 |
|
49 * @return instance of CWsfDetailsView class |
|
50 */ |
|
51 static CWsfDetailsView* NewL(); |
|
52 |
|
53 /** |
|
54 * Two-phased constructor. Leaves the object on CleanupStack |
|
55 * @since S60 5.0 |
|
56 * @return instance of CWsfDetailsView class |
|
57 */ |
|
58 static CWsfDetailsView* NewLC(); |
|
59 |
|
60 /** |
|
61 * Destructor of CWsfDetailsView class |
|
62 * @since S60 5.0 |
|
63 */ |
|
64 ~CWsfDetailsView(); |
|
65 |
|
66 // Methods from CAknView |
|
67 |
|
68 /** |
|
69 * Returns views id. |
|
70 * @since S60 5.0 |
|
71 * @return id for this view. |
|
72 */ |
|
73 TUid Id() const; |
|
74 |
|
75 /** |
|
76 * Command handling function. |
|
77 * @since S60 5.0 |
|
78 * @param aCommand ID of the command to respond to. |
|
79 */ |
|
80 void HandleCommandL( TInt aCommand ); |
|
81 |
|
82 |
|
83 // Methods from MEikListBoxObserver |
|
84 |
|
85 /** |
|
86 * From MEikListBoxObserver. |
|
87 * Handles listbox events. |
|
88 * @since S60 5.0 |
|
89 * @param aListBox listbox pointer. |
|
90 * @param aEventType event type. |
|
91 */ |
|
92 void HandleListBoxEventL( CEikListBox* aListBox, |
|
93 TListBoxEvent aEventType ); |
|
94 |
|
95 // New methods |
|
96 |
|
97 /** |
|
98 * Return controller interface |
|
99 * @since S60 5.0 |
|
100 * @return controiller interface |
|
101 */ |
|
102 MWsfDetailsViewControllerIf& Controller(); |
|
103 |
|
104 |
|
105 protected: |
|
106 |
|
107 // Functions from CAknView |
|
108 |
|
109 /** |
|
110 * From CAknView. |
|
111 * Called when view is activated. |
|
112 * @since S60 5.0 |
|
113 * @param aPrevViewId previous view id. |
|
114 * @param aCustomMessageId custom message id. |
|
115 * @param aCustomMessage custom message content. |
|
116 */ |
|
117 void DoActivateL( const TVwsViewId& aPrevViewId, |
|
118 TUid aCustomMessageId, |
|
119 const TDesC8& aCustomMessage ); |
|
120 |
|
121 /** |
|
122 * From CAknView. |
|
123 * Called when view is deactivated. |
|
124 */ |
|
125 void DoDeactivate(); |
|
126 |
|
127 private: // Constructors and destructor |
|
128 |
|
129 /** |
|
130 * Default C++ constructor |
|
131 * @since S60 5.0 |
|
132 */ |
|
133 CWsfDetailsView(); |
|
134 |
|
135 /** |
|
136 * 2nd phase constructor |
|
137 * @since S60 5.0 |
|
138 */ |
|
139 void ConstructL(); |
|
140 |
|
141 private: // Data |
|
142 |
|
143 /** |
|
144 * Details view container |
|
145 * Own. |
|
146 */ |
|
147 CWsfDetailsContainer* iContainer; |
|
148 |
|
149 /** |
|
150 * Controller of Details view |
|
151 * Own. |
|
152 */ |
|
153 TWsfDetailsViewController iController; |
|
154 |
|
155 /** |
|
156 * Details view Model |
|
157 * Own. |
|
158 */ |
|
159 CWsfDetailsViewModel* iModel; |
|
160 |
|
161 }; |
|
162 |
|
163 #endif // C_WSFDETAILSVIEW_H |
|
164 |
|
165 // End of File |
|