1 /* |
|
2 * Copyright (c) 2009 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: |
|
15 * |
|
16 */ |
|
17 |
|
18 |
|
19 |
|
20 |
|
21 |
|
22 |
|
23 |
|
24 |
|
25 |
|
26 |
|
27 #ifndef __AKNFEPDUALLANGUAGESETTINGDATA_H |
|
28 #define __AKNFEPDUALLANGUAGESETTINGDATA_H |
|
29 |
|
30 #include <e32base.h> |
|
31 #include <badesca.h> |
|
32 #include <aknsettingitemlist.h> |
|
33 |
|
34 /** |
|
35 * Class: CAknFepDualLanguageSettingData |
|
36 * |
|
37 * Discussion: An aggregate class containing data for all editing controls |
|
38 * This class is used as a central respository for all data |
|
39 * to be displayed and editted within this app. |
|
40 */ |
|
41 class CAknFepDualLanguageSettingData : public CBase |
|
42 { |
|
43 public: |
|
44 /** |
|
45 * Function: NewL |
|
46 * |
|
47 * Discussion: Factory function used to create a new instance of |
|
48 * CAknFepDualLanguageSettingData |
|
49 * |
|
50 * Returns: A newly created instance of CAknFepDualLanguageSettingData with all data |
|
51 * items valid |
|
52 */ |
|
53 static CAknFepDualLanguageSettingData* NewL(); |
|
54 |
|
55 /** |
|
56 * Function: NewLC |
|
57 * |
|
58 * Discussion: Factory function used to create a new instance of |
|
59 * CAknFepDualLanguageSettingData and leave a pointer to it on the cleanup |
|
60 * stack |
|
61 * |
|
62 * Returns: A newly created instance of CAknFepDualLanguageSettingData with all data |
|
63 * items valid |
|
64 */ |
|
65 static CAknFepDualLanguageSettingData* NewLC(); |
|
66 |
|
67 /** |
|
68 * Function: ~CAknFepDualLanguageSettingData |
|
69 * |
|
70 * Discussion: Virtual destructor for CCAknFepDualLanguageSettingData. Ensures that all |
|
71 * allocated memory is returned to the heap before deletion |
|
72 * of object. |
|
73 * |
|
74 */ |
|
75 virtual ~CAknFepDualLanguageSettingData(); |
|
76 |
|
77 /** |
|
78 * Function: LoadL |
|
79 * |
|
80 * Discussion: Loads itself with parameters passed. |
|
81 * |
|
82 */ |
|
83 void LoadL(CDesCArrayFlat* aItems, |
|
84 CDesCArrayFlat* aSecondaryItems, |
|
85 TInt aCurrentValue, |
|
86 TInt aCurrentSecondaryValue); |
|
87 |
|
88 |
|
89 /** |
|
90 * Function: SaveL |
|
91 * |
|
92 * Discussion: Saves itself. |
|
93 * |
|
94 */ |
|
95 void SaveL() const; |
|
96 |
|
97 /** |
|
98 * Function: Items |
|
99 * |
|
100 * Discussion: Trivial accessor function |
|
101 * |
|
102 * Returns: A reference to the iItems member |
|
103 */ |
|
104 inline CDesCArrayFlat* Items() {return iItems; } |
|
105 |
|
106 /** |
|
107 * Function: SecondaryItems |
|
108 * |
|
109 * Discussion: Trivial accessor function |
|
110 * |
|
111 * Returns: A reference to the iSecondaryItems member |
|
112 */ |
|
113 inline CDesCArrayFlat* SecondaryItems() { return iSecondaryItems; } |
|
114 |
|
115 /** |
|
116 * Function: CurrentValue |
|
117 * |
|
118 * Discussion: Trivial accessor function |
|
119 * |
|
120 * Returns: A reference to the iCurrentValue member |
|
121 */ |
|
122 inline TInt& CurrentValue() {return iCurrentValue; } |
|
123 |
|
124 /** |
|
125 * Function: CurrentSecondaryValue |
|
126 * |
|
127 * Discussion: Trivial accessor function |
|
128 * |
|
129 * Returns: A reference to the iCurrentSecondaryValue member |
|
130 */ |
|
131 inline TInt& CurrentSecondaryValue() {return iCurrentSecondaryValue; } |
|
132 |
|
133 private: |
|
134 /** |
|
135 * Function: CAknFepDualLanguageSettingData |
|
136 * |
|
137 * Discussion: Hidden, first-stage non-leaving constructor. |
|
138 * |
|
139 */ |
|
140 CAknFepDualLanguageSettingData(); |
|
141 |
|
142 /** |
|
143 * Function: ConstructL |
|
144 * |
|
145 * Discussion: Hidden, second-stage possibly-leaving constructor. |
|
146 * |
|
147 */ |
|
148 void ConstructL(); |
|
149 |
|
150 |
|
151 public: |
|
152 CDesCArrayFlat* iItems; |
|
153 CDesCArrayFlat* iSecondaryItems; |
|
154 TInt iCurrentValue; |
|
155 TInt iCurrentSecondaryValue; |
|
156 }; |
|
157 |
|
158 #endif // __AKNFEPDUALLANGUAGESETTINGDATA_H |
|
159 |
|