|
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: Setting item list class for Video settings list view.* |
|
15 */ |
|
16 |
|
17 |
|
18 // Version : %version: 7 % |
|
19 |
|
20 |
|
21 |
|
22 |
|
23 #ifndef MPSETTINGSVIDEOSETTINGITEMLIST_H |
|
24 #define MPSETTINGSVIDEOSETTINGITEMLIST_H |
|
25 |
|
26 // INCLUDES |
|
27 #include <aknsettingitemlist.h> |
|
28 |
|
29 // CONSTANTS |
|
30 |
|
31 |
|
32 // When video contrast is not drawn, we know to shift the contents |
|
33 const TInt KVideoContrastNotSupported ( -99 ); |
|
34 |
|
35 // FORWARD DECLARATIONS |
|
36 class CMPSettingsModelForROP; |
|
37 class CVcxNsSettingsEngine; |
|
38 |
|
39 // CLASS DECLARATION |
|
40 |
|
41 /** |
|
42 * CMPSettingsVideoSettingItemList |
|
43 * Setting item list class for Video settings list view. |
|
44 * |
|
45 * @lib MediaSettings.app |
|
46 * @since 2.0 |
|
47 */ |
|
48 class CMPSettingsVideoSettingItemList : public CAknSettingItemList |
|
49 { |
|
50 public: // Constructors and destructor |
|
51 |
|
52 /** |
|
53 * Setting listbox's item idexes |
|
54 */ |
|
55 typedef enum |
|
56 { |
|
57 EVideoSettingContrast = 0, |
|
58 EVcSettingsViewParentControlIndex, |
|
59 EVcSettingsViewMemoryItemIndex, |
|
60 EVcSettingsViewThumbnailsIndex, |
|
61 EVideoPlayerVersion, |
|
62 EVcSettingsViewIadUpdateItemIndex // non-editable item |
|
63 } TVideoSettingItemIndex; |
|
64 |
|
65 /** |
|
66 * C++ default constructor. |
|
67 */ |
|
68 CMPSettingsVideoSettingItemList( CMPSettingsModelForROP* aModel, |
|
69 CVcxNsSettingsEngine& aVideoSettingsEngine ); |
|
70 |
|
71 /** |
|
72 * Destructor. |
|
73 */ |
|
74 virtual ~CMPSettingsVideoSettingItemList(); |
|
75 |
|
76 public: |
|
77 |
|
78 /** |
|
79 * Check if specified item is currently selected. |
|
80 * |
|
81 * @param aIndex Item index |
|
82 */ |
|
83 TBool IsCurrentItem( TInt aIndex ); |
|
84 |
|
85 /** |
|
86 * Check wheter or not the Contrast settings item shold be drawn |
|
87 */ |
|
88 TBool VideoContrastIsSupportedL(); |
|
89 |
|
90 public: // Functions from base classes |
|
91 |
|
92 /** |
|
93 * From CAknSettingItemList |
|
94 */ |
|
95 void EditItemL(TInt aIndex, TBool aCalledFromMenu); |
|
96 |
|
97 /** |
|
98 * Opens current setting item for editing. |
|
99 * |
|
100 * @param aCalledFromMenu ETrue if started from menu. |
|
101 */ |
|
102 void EditCurrentItemL( TBool aCalledFromMenu ); |
|
103 |
|
104 /** |
|
105 * From CAknSettingItemList |
|
106 */ |
|
107 void LoadSettingsL(); |
|
108 |
|
109 protected: // Functions from base classes |
|
110 |
|
111 /** |
|
112 * From CAknSettingItemList |
|
113 */ |
|
114 CAknSettingItem* CreateSettingItemL(TInt aSettingId); |
|
115 |
|
116 private: //New |
|
117 |
|
118 /** |
|
119 * Loads a specific setting value. |
|
120 * @since 2.0 |
|
121 * @param aSettingId ID of the setting to be loaded. |
|
122 */ |
|
123 void LoadSettingL(TInt aSettingId); |
|
124 |
|
125 /** |
|
126 * Stores a specific setting value. |
|
127 * @since 2.0 |
|
128 * @param aSettingId ID of the setting to be stored. |
|
129 */ |
|
130 void StoreSettingL(TInt aSettingId); |
|
131 |
|
132 /** |
|
133 * Loads all setting values. |
|
134 * @since 2.0 |
|
135 */ |
|
136 void LoadAllL(); |
|
137 |
|
138 /** |
|
139 * Event handling section, from MEikListBoxObserver. |
|
140 */ |
|
141 void HandleListBoxEventL(CEikListBox* aListBox, TListBoxEvent aListBoxEvent); |
|
142 |
|
143 private: |
|
144 CMPSettingsModelForROP* iModel; |
|
145 CVcxNsSettingsEngine& iVideoSettingsEngine; // Video settings engine |
|
146 |
|
147 TInt iSettingTemp; // Dummy setting placeholder for settings sublist items |
|
148 |
|
149 TInt iVideoContrast; |
|
150 TBool iVideoRepeatMode; |
|
151 TBool iVideoDefaultViewMode; |
|
152 TBool iRockerKeysMode; |
|
153 TBool iRockerKeysSupported; |
|
154 TBool iLandscapeSupportedByDevice; |
|
155 }; |
|
156 |
|
157 #endif // MPSETTINGSVIDEOSETTINGITEMLIST_H |
|
158 |
|
159 // End of File |