|
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: For test alf core toolkit api modules |
|
15 * |
|
16 */ |
|
17 |
|
18 |
|
19 |
|
20 // [INCLUDE FILES] |
|
21 #include <e32svr.h> |
|
22 #include <stifparser.h> |
|
23 #include <stiftestinterface.h> |
|
24 #include <uiacceltk/huienv.h> |
|
25 #include <uiacceltk/huicontrol.h> |
|
26 #include <uiacceltk/huicontrolgroup.h> |
|
27 #include <uiacceltk/huivisual.h> |
|
28 #include <uiacceltk/huianchorlayout.h> |
|
29 #include <uiacceltk/huievent.h> |
|
30 #include <eikenv.h> |
|
31 #include <e32err.h> |
|
32 |
|
33 #include "testuiaifcoretoolkit.h" |
|
34 // ----------------------------------------------------------------------------- |
|
35 // CTestUiAifCoreToolkit::TestCHuiCntlGroupAppendL |
|
36 // ----------------------------------------------------------------------------- |
|
37 // |
|
38 TInt CTestUiAifCoreToolkit::TestCHuiCntlGroupAppendL( CStifItemParser& /*aItem*/ ) |
|
39 { |
|
40 |
|
41 // Print to UI |
|
42 _LIT( Ktestuiaifcoretoolkit, "testuiaifcoretoolkit" ); |
|
43 _LIT( KTestCHuiCntlGroupAppendL, "In TestCHuiCntlGroupAppendL" ); |
|
44 TestModuleIf().Printf( 0, Ktestuiaifcoretoolkit, KTestCHuiCntlGroupAppendL ); |
|
45 // Print to log file |
|
46 iLog->Log( KTestCHuiCntlGroupAppendL ); |
|
47 |
|
48 STIF_ASSERT_NOT_NULL( iHuiEnv ); |
|
49 STIF_ASSERT_NOT_NULL( iHuiControl ); |
|
50 CHuiControl* otherControl = new( ELeave ) CHuiControl( *iHuiEnv ); |
|
51 STIF_ASSERT_NOT_NULL( otherControl ); |
|
52 CleanupStack::PushL( otherControl ); |
|
53 iHuiControl->SetId( 0 ); |
|
54 STIF_ASSERT_NOT_NULL( iHuiControlGroup ); |
|
55 iHuiControlGroup->AppendL( otherControl ); |
|
56 CleanupStack::Pop( 1 ); |
|
57 |
|
58 return KErrNone; |
|
59 |
|
60 } |
|
61 // ----------------------------------------------------------------------------- |
|
62 // CTestUiAifCoreToolkit::TestCHuiCntlGroupAppendAndPopL |
|
63 // ----------------------------------------------------------------------------- |
|
64 // |
|
65 TInt CTestUiAifCoreToolkit::TestCHuiCntlGroupAppendAndPopL( CStifItemParser& /*aItem*/ ) |
|
66 { |
|
67 |
|
68 // Print to UI |
|
69 _LIT( Ktestuiaifcoretoolkit, "testuiaifcoretoolkit" ); |
|
70 _LIT( KTestCHuiCntlGroupAppendAndPopL, "In TestCHuiCntlGroupAppendAndPopL" ); |
|
71 TestModuleIf().Printf( 0, Ktestuiaifcoretoolkit, KTestCHuiCntlGroupAppendAndPopL ); |
|
72 // Print to log file |
|
73 iLog->Log( KTestCHuiCntlGroupAppendAndPopL ); |
|
74 |
|
75 STIF_ASSERT_NOT_NULL( iHuiEnv ); |
|
76 STIF_ASSERT_NOT_NULL( iHuiControl ); |
|
77 CHuiControl* otherControl = new( ELeave ) CHuiControl( *iHuiEnv ); |
|
78 STIF_ASSERT_NOT_NULL( otherControl ); |
|
79 CleanupStack::PushL( otherControl ); |
|
80 iHuiControl->SetId( 0 ); |
|
81 STIF_ASSERT_NOT_NULL( iHuiControlGroup ); |
|
82 iHuiControlGroup->AppendAndPopL( otherControl ); |
|
83 |
|
84 return KErrNone; |
|
85 |
|
86 } |
|
87 // ----------------------------------------------------------------------------- |
|
88 // CTestUiAifCoreToolkit::TestCHuiCntlGroupRemoveL |
|
89 // ----------------------------------------------------------------------------- |
|
90 // |
|
91 TInt CTestUiAifCoreToolkit::TestCHuiCntlGroupRemoveL( CStifItemParser& /*aItem*/ ) |
|
92 { |
|
93 |
|
94 // Print to UI |
|
95 _LIT( Ktestuiaifcoretoolkit, "testuiaifcoretoolkit" ); |
|
96 _LIT( KTestCHuiCntlGroupRemoveL, "In TestCHuiCntlGroupRemoveL" ); |
|
97 TestModuleIf().Printf( 0, Ktestuiaifcoretoolkit, KTestCHuiCntlGroupRemoveL ); |
|
98 // Print to log file |
|
99 iLog->Log( KTestCHuiCntlGroupRemoveL ); |
|
100 |
|
101 STIF_ASSERT_NOT_NULL( iHuiEnv ); |
|
102 STIF_ASSERT_NOT_NULL( iHuiControl ); |
|
103 CHuiControl* otherControl = new( ELeave ) CHuiControl( *iHuiEnv ); |
|
104 STIF_ASSERT_NOT_NULL( otherControl ); |
|
105 CleanupStack::PushL( otherControl ); |
|
106 iHuiControl->SetId( 0 ); |
|
107 STIF_ASSERT_NOT_NULL( iHuiControlGroup ); |
|
108 iHuiControlGroup->AppendAndPopL( otherControl ); |
|
109 iHuiControlGroup->Remove( otherControl ); |
|
110 |
|
111 return KErrNone; |
|
112 |
|
113 } |
|
114 // ----------------------------------------------------------------------------- |
|
115 // CTestUiAifCoreToolkit::TestCHuiCntlCountL |
|
116 // ----------------------------------------------------------------------------- |
|
117 // |
|
118 TInt CTestUiAifCoreToolkit::TestCHuiCntlCountL( CStifItemParser& /*aItem*/ ) |
|
119 { |
|
120 |
|
121 // Print to UI |
|
122 _LIT( Ktestuiaifcoretoolkit, "testuiaifcoretoolkit" ); |
|
123 _LIT( KTestCHuiCntlCountL, "In TestCHuiCntlCountL" ); |
|
124 TestModuleIf().Printf( 0, Ktestuiaifcoretoolkit, KTestCHuiCntlCountL ); |
|
125 // Print to log file |
|
126 iLog->Log( KTestCHuiCntlCountL ); |
|
127 |
|
128 STIF_ASSERT_NOT_NULL( iHuiEnv ); |
|
129 STIF_ASSERT_NOT_NULL( iHuiControl ); |
|
130 CHuiControl* otherControl = new( ELeave ) CHuiControl( *iHuiEnv ); |
|
131 STIF_ASSERT_NOT_NULL( otherControl ); |
|
132 CleanupStack::PushL( otherControl ); |
|
133 iHuiControl->SetId( 0 ); |
|
134 iHuiControlGroup->AppendL( otherControl ); |
|
135 TInt count = iHuiControlGroup->Count(); |
|
136 CleanupStack::Pop( 1 ); |
|
137 |
|
138 return KErrNone; |
|
139 |
|
140 } |
|
141 // ----------------------------------------------------------------------------- |
|
142 // CTestUiAifCoreToolkit::TestCHuiCntlControlL |
|
143 // ----------------------------------------------------------------------------- |
|
144 // |
|
145 TInt CTestUiAifCoreToolkit::TestCHuiCntlControlL( CStifItemParser& /*aItem*/ ) |
|
146 { |
|
147 |
|
148 // Print to UI |
|
149 _LIT( Ktestuiaifcoretoolkit, "testuiaifcoretoolkit" ); |
|
150 _LIT( KTestCHuiCntlControlL, "In TestCHuiCntlControlL" ); |
|
151 TestModuleIf().Printf( 0, Ktestuiaifcoretoolkit, KTestCHuiCntlControlL ); |
|
152 // Print to log file |
|
153 iLog->Log( KTestCHuiCntlControlL ); |
|
154 |
|
155 STIF_ASSERT_NOT_NULL( iHuiEnv ); |
|
156 STIF_ASSERT_NOT_NULL( iHuiControl ); |
|
157 CHuiControl* otherControl = new( ELeave ) CHuiControl( *iHuiEnv ); |
|
158 STIF_ASSERT_NOT_NULL( otherControl ); |
|
159 CleanupStack::PushL( otherControl ); |
|
160 iHuiControl->SetId( 0 ); |
|
161 STIF_ASSERT_NOT_NULL( iHuiControlGroup ); |
|
162 iHuiControlGroup->AppendL( otherControl ); |
|
163 TInt count = iHuiControlGroup->Count(); |
|
164 CHuiControl& control = iHuiControlGroup->Control( 0 ); |
|
165 CleanupStack::Pop( 1 ); |
|
166 |
|
167 return KErrNone; |
|
168 |
|
169 } |
|
170 // ----------------------------------------------------------------------------- |
|
171 // CTestUiAifCoreToolkit::TestCHuiCntlFindControlL |
|
172 // ----------------------------------------------------------------------------- |
|
173 // |
|
174 TInt CTestUiAifCoreToolkit::TestCHuiCntlFindControlL( CStifItemParser& /*aItem*/ ) |
|
175 { |
|
176 |
|
177 // Print to UI |
|
178 _LIT( Ktestuiaifcoretoolkit, "testuiaifcoretoolkit" ); |
|
179 _LIT( KTestCHuiCntlFindControlL, "In TestCHuiCntlFindControlL" ); |
|
180 TestModuleIf().Printf( 0, Ktestuiaifcoretoolkit, KTestCHuiCntlFindControlL ); |
|
181 // Print to log file |
|
182 iLog->Log( KTestCHuiCntlFindControlL ); |
|
183 |
|
184 STIF_ASSERT_NOT_NULL( iHuiEnv ); |
|
185 STIF_ASSERT_NOT_NULL( iHuiControl ); |
|
186 CHuiControl* otherControl = new( ELeave ) CHuiControl( *iHuiEnv ); |
|
187 STIF_ASSERT_NOT_NULL( otherControl ); |
|
188 CleanupStack::PushL( otherControl ); |
|
189 iHuiControl->SetId( 0 ); |
|
190 STIF_ASSERT_NOT_NULL( iHuiControlGroup ); |
|
191 iHuiControlGroup->AppendL( otherControl ); |
|
192 TInt count = iHuiControlGroup->Count(); |
|
193 CHuiControl& control = iHuiControlGroup->Control( 0 ); |
|
194 otherControl->SetId( 1 ); |
|
195 CHuiControl* control2 = iHuiControlGroup->FindControl( 1 ); |
|
196 CleanupStack::Pop( 1 ); |
|
197 |
|
198 return KErrNone; |
|
199 |
|
200 } |
|
201 // ----------------------------------------------------------------------------- |
|
202 // CTestUiAifCoreToolkit::TestCHuiCntlEnableTsfomatonL |
|
203 // ----------------------------------------------------------------------------- |
|
204 // |
|
205 TInt CTestUiAifCoreToolkit::TestCHuiCntlEnableTsfomatonL( CStifItemParser& /*aItem*/ ) |
|
206 { |
|
207 |
|
208 // Print to UI |
|
209 _LIT( Ktestuiaifcoretoolkit, "testuiaifcoretoolkit" ); |
|
210 _LIT( KTestCHuiCntlEnableTsfomatonL, "In TestCHuiCntlEnableTsfomatonL" ); |
|
211 TestModuleIf().Printf( 0, Ktestuiaifcoretoolkit, KTestCHuiCntlEnableTsfomatonL ); |
|
212 // Print to log file |
|
213 iLog->Log( KTestCHuiCntlEnableTsfomatonL ); |
|
214 |
|
215 STIF_ASSERT_NOT_NULL( iHuiEnv ); |
|
216 STIF_ASSERT_NOT_NULL( iHuiControl ); |
|
217 CHuiControl* otherControl = new( ELeave ) CHuiControl( *iHuiEnv ); |
|
218 STIF_ASSERT_NOT_NULL( otherControl ); |
|
219 CleanupStack::PushL( otherControl ); |
|
220 iHuiControl->SetId( 0 ); |
|
221 STIF_ASSERT_NOT_NULL( iHuiControlGroup ); |
|
222 iHuiControlGroup->AppendL( otherControl ); |
|
223 iHuiControlGroup->EnableTransformationL(); |
|
224 CleanupStack::Pop( 1 ); |
|
225 |
|
226 return KErrNone; |
|
227 |
|
228 } |
|
229 // ----------------------------------------------------------------------------- |
|
230 // CTestUiAifCoreToolkit::TestCHuiCntlIsTransformedL |
|
231 // ----------------------------------------------------------------------------- |
|
232 // |
|
233 TInt CTestUiAifCoreToolkit::TestCHuiCntlIsTransformedL( CStifItemParser& /*aItem*/ ) |
|
234 { |
|
235 |
|
236 // Print to UI |
|
237 _LIT( Ktestuiaifcoretoolkit, "testuiaifcoretoolkit" ); |
|
238 _LIT( KTestCHuiCntlIsTransformedL, "In TestCHuiCntlIsTransformedL" ); |
|
239 TestModuleIf().Printf( 0, Ktestuiaifcoretoolkit, KTestCHuiCntlIsTransformedL ); |
|
240 // Print to log file |
|
241 iLog->Log( KTestCHuiCntlIsTransformedL ); |
|
242 |
|
243 STIF_ASSERT_NOT_NULL( iHuiEnv ); |
|
244 STIF_ASSERT_NOT_NULL( iHuiControl ); |
|
245 CHuiControl* otherControl = new( ELeave ) CHuiControl( *iHuiEnv ); |
|
246 STIF_ASSERT_NOT_NULL( otherControl ); |
|
247 CleanupStack::PushL( otherControl ); |
|
248 iHuiControl->SetId( 0 ); |
|
249 STIF_ASSERT_NOT_NULL( iHuiControlGroup ); |
|
250 iHuiControlGroup->AppendL( otherControl ); |
|
251 TBool isTransformed = iHuiControlGroup->IsTransformed(); |
|
252 CleanupStack::Pop( 1 ); |
|
253 |
|
254 return KErrNone; |
|
255 |
|
256 } |
|
257 // ----------------------------------------------------------------------------- |
|
258 // CTestUiAifCoreToolkit::TestCHuiCntlTransformationL |
|
259 // ----------------------------------------------------------------------------- |
|
260 // |
|
261 TInt CTestUiAifCoreToolkit::TestCHuiCntlTransformationL( CStifItemParser& /*aItem*/ ) |
|
262 { |
|
263 |
|
264 // Print to UI |
|
265 _LIT( Ktestuiaifcoretoolkit, "testuiaifcoretoolkit" ); |
|
266 _LIT( KTestCHuiCntlTransformationL, "In TestCHuiCntlTransformationL" ); |
|
267 TestModuleIf().Printf( 0, Ktestuiaifcoretoolkit, KTestCHuiCntlTransformationL ); |
|
268 // Print to log file |
|
269 iLog->Log( KTestCHuiCntlTransformationL ); |
|
270 |
|
271 STIF_ASSERT_NOT_NULL( iHuiEnv ); |
|
272 STIF_ASSERT_NOT_NULL( iHuiControl ); |
|
273 CHuiControl* otherControl = new( ELeave ) CHuiControl( *iHuiEnv ); |
|
274 STIF_ASSERT_NOT_NULL( otherControl ); |
|
275 CleanupStack::PushL( otherControl ); |
|
276 iHuiControl->SetId( 0 ); |
|
277 STIF_ASSERT_NOT_NULL( iHuiControlGroup ); |
|
278 iHuiControlGroup->AppendL( otherControl ); |
|
279 TBool isTransformed = iHuiControlGroup->IsTransformed(); |
|
280 iHuiControlGroup->EnableTransformationL( ETrue ); |
|
281 CHuiTransformation& transformation = iHuiControlGroup->Transformation(); |
|
282 CleanupStack::Pop( 1 ); |
|
283 |
|
284 return KErrNone; |
|
285 |
|
286 } |
|
287 // ----------------------------------------------------------------------------- |
|
288 // CTestUiAifCoreToolkit::TestCHuiCntlAcceptInputL |
|
289 // ----------------------------------------------------------------------------- |
|
290 // |
|
291 TInt CTestUiAifCoreToolkit::TestCHuiCntlAcceptInputL( CStifItemParser& /*aItem*/ ) |
|
292 { |
|
293 |
|
294 // Print to UI |
|
295 _LIT( Ktestuiaifcoretoolkit, "testuiaifcoretoolkit" ); |
|
296 _LIT( KTestCHuiCntlAcceptInputL, "In TestCHuiCntlAcceptInputL" ); |
|
297 TestModuleIf().Printf( 0, Ktestuiaifcoretoolkit, KTestCHuiCntlAcceptInputL ); |
|
298 // Print to log file |
|
299 iLog->Log( KTestCHuiCntlAcceptInputL ); |
|
300 |
|
301 STIF_ASSERT_NOT_NULL( iHuiEnv ); |
|
302 STIF_ASSERT_NOT_NULL( iHuiControl ); |
|
303 CHuiControl* otherControl = new( ELeave ) CHuiControl( *iHuiEnv ); |
|
304 STIF_ASSERT_NOT_NULL( otherControl ); |
|
305 CleanupStack::PushL( otherControl ); |
|
306 iHuiControl->SetId( 0 ); |
|
307 STIF_ASSERT_NOT_NULL( iHuiControlGroup ); |
|
308 iHuiControlGroup->AppendL( otherControl ); |
|
309 TBool isTransformed = iHuiControlGroup->IsTransformed(); |
|
310 iHuiControlGroup->EnableTransformationL( ETrue ); |
|
311 CHuiTransformation& transformation = iHuiControlGroup->Transformation(); |
|
312 TBool isAcceptInput = iHuiControlGroup->AcceptInput(); |
|
313 CleanupStack::Pop( 1 ); |
|
314 |
|
315 return KErrNone; |
|
316 |
|
317 } |
|
318 // ----------------------------------------------------------------------------- |
|
319 // CTestUiAifCoreToolkit::TestCHuiCntlSetAcceptInputL |
|
320 // ----------------------------------------------------------------------------- |
|
321 // |
|
322 TInt CTestUiAifCoreToolkit::TestCHuiCntlSetAcceptInputL( CStifItemParser& /*aItem*/ ) |
|
323 { |
|
324 |
|
325 // Print to UI |
|
326 _LIT( Ktestuiaifcoretoolkit, "testuiaifcoretoolkit" ); |
|
327 _LIT( KTestCHuiCntlSetAcceptInputL, "In TestCHuiCntlSetAcceptInputL" ); |
|
328 TestModuleIf().Printf( 0, Ktestuiaifcoretoolkit, KTestCHuiCntlSetAcceptInputL ); |
|
329 // Print to log file |
|
330 iLog->Log( KTestCHuiCntlSetAcceptInputL ); |
|
331 |
|
332 STIF_ASSERT_NOT_NULL( iHuiEnv ); |
|
333 STIF_ASSERT_NOT_NULL( iHuiControl ); |
|
334 CHuiControl* otherControl = new( ELeave ) CHuiControl( *iHuiEnv ); |
|
335 STIF_ASSERT_NOT_NULL( otherControl ); |
|
336 CleanupStack::PushL( otherControl ); |
|
337 iHuiControl->SetId( 0 ); |
|
338 STIF_ASSERT_NOT_NULL( iHuiControlGroup ); |
|
339 iHuiControlGroup->AppendL( otherControl ); |
|
340 TBool isTransformed = iHuiControlGroup->IsTransformed(); |
|
341 iHuiControlGroup->EnableTransformationL( ETrue ); |
|
342 CHuiTransformation& transformation = iHuiControlGroup->Transformation(); |
|
343 TBool isAcceptInput = iHuiControlGroup->AcceptInput(); |
|
344 iHuiControlGroup->SetAcceptInput( ETrue ); |
|
345 CleanupStack::Pop( 1 ); |
|
346 |
|
347 return KErrNone; |
|
348 |
|
349 } |
|
350 // ----------------------------------------------------------------------------- |
|
351 // CTestUiAifCoreToolkit::TestCHuiCntlTypeL |
|
352 // ----------------------------------------------------------------------------- |
|
353 // |
|
354 TInt CTestUiAifCoreToolkit::TestCHuiCntlTypeL( CStifItemParser& /*aItem*/ ) |
|
355 { |
|
356 |
|
357 // Print to UI |
|
358 _LIT( Ktestuiaifcoretoolkit, "testuiaifcoretoolkit" ); |
|
359 _LIT( KTestCHuiCntlTypeL, "In TestCHuiCntlChangedL" ); |
|
360 TestModuleIf().Printf( 0, Ktestuiaifcoretoolkit, KTestCHuiCntlTypeL ); |
|
361 // Print to log file |
|
362 iLog->Log( KTestCHuiCntlTypeL ); |
|
363 |
|
364 STIF_ASSERT_NOT_NULL( iHuiEnv ); |
|
365 STIF_ASSERT_NOT_NULL( iHuiControl ); |
|
366 CHuiControl* otherControl = new( ELeave ) CHuiControl( *iHuiEnv ); |
|
367 STIF_ASSERT_NOT_NULL( otherControl ); |
|
368 CleanupStack::PushL( otherControl ); |
|
369 iHuiControl->SetId( 0 ); |
|
370 STIF_ASSERT_NOT_NULL( iHuiControlGroup ); |
|
371 iHuiControlGroup->AppendL( otherControl ); |
|
372 TBool isTransformed = iHuiControlGroup->IsTransformed(); |
|
373 iHuiControlGroup->EnableTransformationL( ETrue ); |
|
374 CHuiTransformation& transformation = iHuiControlGroup->Transformation(); |
|
375 TBool isAcceptInput = iHuiControlGroup->AcceptInput(); |
|
376 iHuiControlGroup->SetAcceptInput( ETrue ); |
|
377 iHuiControlGroup->Type(); |
|
378 CleanupStack::Pop( 1 ); |
|
379 |
|
380 return KErrNone; |
|
381 |
|
382 } |
|
383 // ----------------------------------------------------------------------------- |
|
384 // CTestUiAifCoreToolkit::TestCHuiCntlSessionIdL |
|
385 // ----------------------------------------------------------------------------- |
|
386 // |
|
387 TInt CTestUiAifCoreToolkit::TestCHuiCntlSessionIdL( CStifItemParser& /*aItem*/ ) |
|
388 { |
|
389 |
|
390 // Print to UI |
|
391 _LIT( Ktestuiaifcoretoolkit, "testuiaifcoretoolkit" ); |
|
392 _LIT( KTestCHuiCntlSessionIdL, "In TestCHuiCntlSessionIdL" ); |
|
393 TestModuleIf().Printf( 0, Ktestuiaifcoretoolkit, KTestCHuiCntlSessionIdL ); |
|
394 // Print to log file |
|
395 iLog->Log( KTestCHuiCntlSessionIdL ); |
|
396 |
|
397 STIF_ASSERT_NOT_NULL( iHuiEnv ); |
|
398 STIF_ASSERT_NOT_NULL( iHuiControl ); |
|
399 CHuiControl* otherControl = new( ELeave ) CHuiControl( *iHuiEnv ); |
|
400 STIF_ASSERT_NOT_NULL( otherControl ); |
|
401 CleanupStack::PushL( otherControl ); |
|
402 iHuiControl->SetId( 0 ); |
|
403 STIF_ASSERT_NOT_NULL( iHuiControlGroup ); |
|
404 iHuiControlGroup->AppendL( otherControl ); |
|
405 TBool isTransformed = iHuiControlGroup->IsTransformed(); |
|
406 iHuiControlGroup->EnableTransformationL( ETrue ); |
|
407 CHuiTransformation& transformation = iHuiControlGroup->Transformation(); |
|
408 TBool isAcceptInput = iHuiControlGroup->AcceptInput(); |
|
409 iHuiControlGroup->SetAcceptInput( ETrue ); |
|
410 iHuiControlGroup->Type(); |
|
411 TInt sessionId = iHuiControlGroup->SessionId(); |
|
412 CleanupStack::Pop( 1 ); |
|
413 |
|
414 return KErrNone; |
|
415 |
|
416 } |
|
417 // ----------------------------------------------------------------------------- |
|
418 // CTestUiAifCoreToolkit::TestCHuiCntlSetSessionIdL |
|
419 // ----------------------------------------------------------------------------- |
|
420 // |
|
421 TInt CTestUiAifCoreToolkit::TestCHuiCntlSetSessionIdL( CStifItemParser& /*aItem*/ ) |
|
422 { |
|
423 |
|
424 // Print to UI |
|
425 _LIT( Ktestuiaifcoretoolkit, "testuiaifcoretoolkit" ); |
|
426 _LIT( KTestCHuiCntlSetSessionIdL, "In TestCHuiCntlSetSessionIdL" ); |
|
427 TestModuleIf().Printf( 0, Ktestuiaifcoretoolkit, KTestCHuiCntlSetSessionIdL ); |
|
428 // Print to log file |
|
429 iLog->Log( KTestCHuiCntlSetSessionIdL ); |
|
430 |
|
431 STIF_ASSERT_NOT_NULL( iHuiEnv ); |
|
432 STIF_ASSERT_NOT_NULL( iHuiControl ); |
|
433 CHuiControl* otherControl = new( ELeave ) CHuiControl( *iHuiEnv ); |
|
434 STIF_ASSERT_NOT_NULL( otherControl ); |
|
435 CleanupStack::PushL( otherControl ); |
|
436 iHuiControl->SetId( 0 ); |
|
437 STIF_ASSERT_NOT_NULL( iHuiControlGroup ); |
|
438 iHuiControlGroup->AppendL( otherControl ); |
|
439 iHuiControlGroup->IsTransformed(); |
|
440 iHuiControlGroup->EnableTransformationL( ETrue ); |
|
441 iHuiControlGroup->Transformation(); |
|
442 iHuiControlGroup->AcceptInput(); |
|
443 iHuiControlGroup->SetAcceptInput( ETrue ); |
|
444 iHuiControlGroup->Type(); |
|
445 TInt sessionId = iHuiControlGroup->SessionId(); |
|
446 iHuiControlGroup->SetSessionId( sessionId ); |
|
447 CleanupStack::Pop( 1 ); |
|
448 |
|
449 return KErrNone; |
|
450 |
|
451 } |
|
452 |
|
453 // [End of File] |