1 /* |
|
2 * Copyright (c) 2002 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 the License "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: |
|
15 * View of the information about the active settings |
|
16 * |
|
17 * |
|
18 */ |
|
19 |
|
20 |
|
21 #ifndef SETTINGS_VIEW_H |
|
22 #define SETTINGS_VIEW_H |
|
23 |
|
24 // INCLUDES |
|
25 |
|
26 // #include <eiklbo.h> |
|
27 // #include <ActiveApDb.h> |
|
28 #include "BrowserAppViewBase.h" |
|
29 #include "CommsModel.h" |
|
30 |
|
31 // FORWARD DECLARATION |
|
32 |
|
33 class CSettingsContainer; |
|
34 class MApiProvider; |
|
35 |
|
36 // CLASS DECLARATION |
|
37 |
|
38 /** |
|
39 * View of settings info |
|
40 */ |
|
41 class CBrowserSettingsView: public CBrowserViewBase, |
|
42 public MCommsModelObserver |
|
43 { |
|
44 public: // construction |
|
45 |
|
46 /** |
|
47 * Two-phased constructor |
|
48 * @param aApiProvider The API provider. |
|
49 */ |
|
50 static CBrowserSettingsView* NewLC( MApiProvider& aApiProvider ); |
|
51 |
|
52 /** |
|
53 * Two-phased constructor |
|
54 * @param aApiProvider The API provider. |
|
55 */ |
|
56 static CBrowserSettingsView* NewL( MApiProvider& aApiProvider ); |
|
57 |
|
58 /** |
|
59 * Destructor. |
|
60 */ |
|
61 virtual ~CBrowserSettingsView(); |
|
62 |
|
63 public: // From MCbaSetter (CWmlBrowserViewBase) |
|
64 |
|
65 /** |
|
66 * Return command set id, to be displayed. |
|
67 * @return The command set's resource id. |
|
68 */ |
|
69 TInt CommandSetResourceIdL(); |
|
70 |
|
71 /** |
|
72 * Set command set lsk,rsk,msk dynamically via pointers. |
|
73 * Derived classes should implement, though it can be empty. |
|
74 * If it does nothing, empty softkeys will be assigned |
|
75 * @since 5.0 |
|
76 */ |
|
77 void CommandSetResourceDynL(TSKPair& /*lsk*/, TSKPair& /*rsk*/, TSKPair& /*msk*/) {}; |
|
78 |
|
79 public: // From MCommsModelObserver |
|
80 |
|
81 /** |
|
82 * Handle change in comms model (AP-s). |
|
83 */ |
|
84 void HandleCommsModelChangeL(); |
|
85 |
|
86 public: // from CAknView (CWmlBrowserViewBase) |
|
87 |
|
88 /** |
|
89 * @see CAknView |
|
90 */ |
|
91 void HandleCommandL(TInt aCommand); |
|
92 |
|
93 /** |
|
94 * @see CAknView |
|
95 */ |
|
96 TUid Id() const; |
|
97 |
|
98 /** |
|
99 * Updates the options softkey to reflect the command set. |
|
100 * |
|
101 * @since 3.2 |
|
102 * @param aCommandSet The new "command set". |
|
103 * @return void. |
|
104 */ |
|
105 void UpdateCbaL(TInt aCommandSet); |
|
106 |
|
107 |
|
108 protected: // from CAknView |
|
109 |
|
110 /** |
|
111 * @see CAknView |
|
112 */ |
|
113 void DoActivateL(const TVwsViewId& aPrevViewId,TUid aCustomMessageId,const TDesC8& aCustomMessage); |
|
114 |
|
115 |
|
116 /** |
|
117 * @see CAknView |
|
118 */ |
|
119 void DoDeactivate(); |
|
120 |
|
121 /** |
|
122 * @see CAknView |
|
123 */ |
|
124 void HandleClientRectChange(); |
|
125 |
|
126 /** |
|
127 * @see CAknView |
|
128 */ |
|
129 void HandleForegroundEventL (TBool aForeground); |
|
130 |
|
131 private: // MEikMenuObserver |
|
132 |
|
133 void DynInitMenuPaneL( TInt aResourceId, CEikMenuPane* aMenuPane ); |
|
134 |
|
135 private: // destruction |
|
136 |
|
137 /** |
|
138 * Constructor. |
|
139 * @param aApiProvider The API provider. |
|
140 */ |
|
141 CBrowserSettingsView( MApiProvider& aApiProvider ); |
|
142 |
|
143 /** |
|
144 * SymbianOS default constructor. |
|
145 */ |
|
146 void ConstructL(); |
|
147 |
|
148 private: // members |
|
149 |
|
150 CSettingsContainer* iContainer; |
|
151 |
|
152 TVwsViewId iLastViewId; // The view to switch after closing this |
|
153 }; |
|
154 #endif // SETTINGS_VIEW_H |
|
155 |
|
156 // End of file |
|