1 /* |
|
2 * Copyright (c) 2002 - 2007 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: Test CAknMemorySelectionSettingItemMultidrive.h |
|
15 * |
|
16 */ |
|
17 |
|
18 |
|
19 // [INCLUDE FILES] |
|
20 #include <aknsettingitemlist.h> |
|
21 #include <testsdkcfd.rsg> |
|
22 |
|
23 #include "testsdkcfd.h" |
|
24 #include "testsdkcfdsettingitemmultidrive.h" |
|
25 #include "testsdkcfd.hrh" |
|
26 |
|
27 // ============================ MEMBER FUNCTIONS =============================== |
|
28 |
|
29 // ----------------------------------------------------------------------------- |
|
30 // CTestSDKCFD::TestSettingItemMultiConstructorL |
|
31 // ----------------------------------------------------------------------------- |
|
32 // |
|
33 TInt CTestSDKCFD::TestSettingItemMultiConstructorL(CStifItemParser& /*aItem*/) |
|
34 { |
|
35 _LIT( Ktestsdkcfd, "testsdkcfd" ); |
|
36 _LIT( KExample, "In TestSettingItemMultiConstructorL" ); |
|
37 TestModuleIf().Printf( 0, Ktestsdkcfd, KExample ); |
|
38 iLog->Log(KExample); |
|
39 |
|
40 TDriveNumber selectedDrive = EDriveC; |
|
41 CTestSettingItemMultiDrive* settingitem = |
|
42 new ( ELeave ) CTestSettingItemMultiDrive( ETestSettingItem, selectedDrive ); |
|
43 STIF_ASSERT_NOT_NULL( settingitem ); |
|
44 CleanupStack::PushL( settingitem ); |
|
45 CleanupStack::PopAndDestroy( settingitem ); |
|
46 |
|
47 return KErrNone; |
|
48 } |
|
49 // ----------------------------------------------------------------------------- |
|
50 // CTestSDKCFD::TestSettingItemMultiDeconstructorL |
|
51 // ----------------------------------------------------------------------------- |
|
52 // |
|
53 TInt CTestSDKCFD::TestSettingItemMultiDeconstructorL(CStifItemParser& /*aItem*/) |
|
54 { |
|
55 _LIT( Ktestsdkcfd, "testsdkcfd" ); |
|
56 _LIT( KExample, "In TestSettingItemMultiDeconstructorL" ); |
|
57 TestModuleIf().Printf( 0, Ktestsdkcfd, KExample ); |
|
58 iLog->Log(KExample); |
|
59 |
|
60 |
|
61 return KErrNone; |
|
62 } |
|
63 |
|
64 // ----------------------------------------------------------------------------- |
|
65 // CTestSDKCFD::TestSettingItemMultiCompleteConstructionL |
|
66 // ----------------------------------------------------------------------------- |
|
67 // |
|
68 TInt CTestSDKCFD::TestSettingItemMultiCompleteConstructionL(CStifItemParser& /*aItem*/) |
|
69 { |
|
70 _LIT( Ktestsdkcfd, "testsdkcfd" ); |
|
71 _LIT( KExample, "In TestSettingItemMultiCompleteConstructionL" ); |
|
72 TestModuleIf().Printf( 0, Ktestsdkcfd, KExample ); |
|
73 iLog->Log(KExample); |
|
74 |
|
75 TDriveNumber selectedDrive = EDriveC; |
|
76 CTestSettingItemMultiDrive* settingitem = |
|
77 new ( ELeave ) CTestSettingItemMultiDrive( ETestSettingItem, selectedDrive ); |
|
78 CleanupStack::PushL( settingitem ); |
|
79 settingitem->CompleteConstructionL(); |
|
80 CAknMemorySelectionSettingItemExtension* temp= NULL; |
|
81 temp = settingitem->GetExtensionPointer(); |
|
82 STIF_ASSERT_NOT_NULL( temp ); |
|
83 temp = NULL; |
|
84 CleanupStack::PopAndDestroy( settingitem ); |
|
85 return KErrNone; |
|
86 |
|
87 } |
|
88 |
|
89 // ----------------------------------------------------------------------------- |
|
90 // CTestSDKCFD::TestSettingItemMultiEditItemL |
|
91 // ----------------------------------------------------------------------------- |
|
92 // |
|
93 TInt CTestSDKCFD::TestSettingItemMultiEditItemL(CStifItemParser& /*aItem*/) |
|
94 { |
|
95 _LIT( Ktestsdkcfd, "testsdkcfd" ); |
|
96 _LIT( KExample, "In TestSettingItemMultiEditItemL" ); |
|
97 TestModuleIf().Printf( 0, Ktestsdkcfd, KExample ); |
|
98 iLog->Log(KExample); |
|
99 |
|
100 iSettingItemListMulti = new ( ELeave ) CTestSettingItemListMultiDrive; |
|
101 iSettingItemListMulti->ConstructL(); |
|
102 iSettingItemListMulti->EditItemL( 0, ETrue ); |
|
103 delete iSettingItemListMulti; |
|
104 iSettingItemListMulti = NULL; |
|
105 |
|
106 return KErrNone; |
|
107 } |
|
108 |
|
109 // ----------------------------------------------------------------------------- |
|
110 // CTestSDKCFD::TestSettingItemMultiLoadL |
|
111 // ----------------------------------------------------------------------------- |
|
112 // |
|
113 TInt CTestSDKCFD::TestSettingItemMultiLoadL(CStifItemParser& /*aItem*/) |
|
114 { |
|
115 _LIT( Ktestsdkcfd, "testsdkcfd" ); |
|
116 _LIT( KExample, "In TestSettingItemMultiLoadL" ); |
|
117 TestModuleIf().Printf( 0, Ktestsdkcfd, KExample ); |
|
118 iLog->Log(KExample); |
|
119 |
|
120 TDriveNumber selectedDrive = EDriveC; |
|
121 CTestSettingItemMultiDrive* settingitem = |
|
122 new ( ELeave ) CTestSettingItemMultiDrive( ETestSettingItem, selectedDrive ); |
|
123 CleanupStack::PushL( settingitem ); |
|
124 settingitem->CompleteConstructionL(); |
|
125 settingitem->LoadL(); |
|
126 CleanupStack::PopAndDestroy( settingitem ); |
|
127 |
|
128 return KErrNone; |
|
129 } |
|
130 |
|
131 // ----------------------------------------------------------------------------- |
|
132 // CTestSDKCFD::TestSettingItemMultiStoreL |
|
133 // ----------------------------------------------------------------------------- |
|
134 // |
|
135 TInt CTestSDKCFD::TestSettingItemMultiStoreL(CStifItemParser& /*aItem*/) |
|
136 { |
|
137 _LIT( Ktestsdkcfd, "testsdkcfd" ); |
|
138 _LIT( KExample, "In TestSettingItemMultiStoreL" ); |
|
139 TestModuleIf().Printf( 0, Ktestsdkcfd, KExample ); |
|
140 iLog->Log(KExample); |
|
141 |
|
142 TDriveNumber selectedDrive = EDriveC; |
|
143 CTestSettingItemMultiDrive* settingitem = |
|
144 new ( ELeave ) CTestSettingItemMultiDrive( ETestSettingItem, selectedDrive ); |
|
145 CleanupStack::PushL( settingitem ); |
|
146 settingitem->CompleteConstructionL(); |
|
147 settingitem->StoreL(); |
|
148 CleanupStack::PopAndDestroy( settingitem ); |
|
149 |
|
150 return KErrNone; |
|
151 } |
|
152 |
|
153 // ----------------------------------------------------------------------------- |
|
154 // CTestSDKCFD::TestSettingItemMultiSettingTextL |
|
155 // ----------------------------------------------------------------------------- |
|
156 // |
|
157 TInt CTestSDKCFD::TestSettingItemMultiSettingTextL(CStifItemParser& /*aItem*/) |
|
158 { |
|
159 _LIT( Ktestsdkcfd, "testsdkcfd" ); |
|
160 _LIT( KExample, "In TestSettingItemMultiSettingTextL" ); |
|
161 TestModuleIf().Printf( 0, Ktestsdkcfd, KExample ); |
|
162 iLog->Log(KExample); |
|
163 |
|
164 TDriveNumber selectedDrive = EDriveC; |
|
165 CTestSettingItemMultiDrive* settingitem = |
|
166 new ( ELeave ) CTestSettingItemMultiDrive( ETestSettingItem, selectedDrive ); |
|
167 CleanupStack::PushL( settingitem ); |
|
168 settingitem->CompleteConstructionL(); |
|
169 settingitem->SettingTextL(); |
|
170 CleanupStack::PopAndDestroy( settingitem ); |
|
171 |
|
172 return KErrNone; |
|
173 } |
|
174 |
|
175 // End of File |
|