|
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 functions in touch_ui_utilities_api |
|
15 * |
|
16 */ |
|
17 |
|
18 |
|
19 |
|
20 #ifndef C_TESTSDKTOUCHUIUTIL_H |
|
21 #define C_TESTSDKTOUCHUIUTIL_H |
|
22 |
|
23 // INCLUDES |
|
24 #include <stiflogger.h> |
|
25 #include <testscripterinternal.h> |
|
26 #include <stiftestmodule.h> |
|
27 #include <testclassassert.h> |
|
28 #include <aknlongtapdetector.h> |
|
29 #include <aknpointereventsuppressor.h> |
|
30 |
|
31 // MACROS |
|
32 #define TEST_CLASS_VERSION_MAJOR 0 |
|
33 #define TEST_CLASS_VERSION_MINOR 0 |
|
34 #define TEST_CLASS_VERSION_BUILD 0 |
|
35 |
|
36 // Logging path |
|
37 _LIT( KtestsdktouchuiutilLogPath, "\\logs\\testframework\\testsdktouchuiutil\\" ); |
|
38 // Log file |
|
39 _LIT( KtestsdktouchuiutilLogFile, "testsdktouchuiutil.txt" ); |
|
40 _LIT( KtestsdktouchuiutilLogFileWithTitle, "testsdktouchuiutil_[%S].txt" ); |
|
41 |
|
42 /** |
|
43 * CTestSDKTouchUiUtil test class for STIF Test Framework TestScripter. |
|
44 * @since S60 5.0 |
|
45 */ |
|
46 NONSHARABLE_CLASS( CTestSDKTouchUiUtil ) : public CScriptBase |
|
47 { |
|
48 public: // Constructors and destructor |
|
49 |
|
50 /** |
|
51 * Two-phased constructor. |
|
52 */ |
|
53 static CTestSDKTouchUiUtil* NewL( CTestModuleIf& aTestModuleIf ); |
|
54 |
|
55 /** |
|
56 * Destructor. |
|
57 */ |
|
58 virtual ~CTestSDKTouchUiUtil(); |
|
59 |
|
60 public: // Functions from base classes |
|
61 |
|
62 /** |
|
63 * From CScriptBase Runs a script line. |
|
64 * @since S60 5.0 |
|
65 * @param aItem Script line containing method name and parameters |
|
66 * @return Symbian OS error code |
|
67 */ |
|
68 virtual TInt RunMethodL( CStifItemParser& aItem ); |
|
69 |
|
70 private: |
|
71 |
|
72 /** |
|
73 * C++ default constructor. |
|
74 */ |
|
75 CTestSDKTouchUiUtil( CTestModuleIf& aTestModuleIf ); |
|
76 |
|
77 /** |
|
78 * By default Symbian 2nd phase constructor is private. |
|
79 */ |
|
80 void ConstructL(); |
|
81 |
|
82 /** |
|
83 * Method used to log version of test class |
|
84 */ |
|
85 void SendTestClassVersion(); |
|
86 |
|
87 /** |
|
88 * Turn off ScreenSaver |
|
89 * @since S60 5.0 |
|
90 * @return Symbian OS error code. |
|
91 */ |
|
92 void TurnOffScreenSaver(); |
|
93 |
|
94 /** |
|
95 * Restore ScreenSaver |
|
96 * @since S60 5.0 |
|
97 * @return Symbian OS error code. |
|
98 */ |
|
99 void RestoreScreenSaver(); |
|
100 |
|
101 private: // [TestMethods] |
|
102 /** |
|
103 * TestCAknLongTapDetectorNewL test NewL of CAknLongTapDetector |
|
104 * in aknlongtapdetector.h. |
|
105 * @since S60 5.0 |
|
106 * @param aItem is not used. |
|
107 * @return Symbian OS error code. |
|
108 */ |
|
109 virtual TInt TestCAknLongTapDetectorNewL( CStifItemParser& aItem ); |
|
110 |
|
111 /** |
|
112 * TestCAknLongTapDetectorNewLC test NewLC of CAknLongTapDetector |
|
113 * in aknlongtapdetector.h. |
|
114 * @since S60 5.0 |
|
115 * @param aItem is not used. |
|
116 * @return Symbian OS error code. |
|
117 */ |
|
118 virtual TInt TestCAknLongTapDetectorNewLC( CStifItemParser& aItem ); |
|
119 |
|
120 /** |
|
121 * TestCAknLongTapDetectorPointerEventL test PointerEventL of CAknLongTapDetector |
|
122 * in aknlongtapdetector.h. |
|
123 * @since S60 5.0 |
|
124 * @param aItem is not used. |
|
125 * @return Symbian OS error code. |
|
126 */ |
|
127 virtual TInt TestCAknLongTapDetectorPointerEventL( CStifItemParser& aItem ); |
|
128 |
|
129 /** |
|
130 * TestCAknLongTapDetectorSetTimeDelayBeforeAnimationL test SetTimeDelayBeforeAnimation of |
|
131 * CAknLongTapDetector in aknlongtapdetector.h. |
|
132 * @since S60 5.0 |
|
133 * @param aItem is not used. |
|
134 * @return Symbian OS error code. |
|
135 */ |
|
136 virtual TInt TestCAknLongTapDetectorSetTimeDelayBeforeAnimationL( CStifItemParser& aItem ); |
|
137 |
|
138 /** |
|
139 * TestCAknLongTapDetectorSetLongTapDelayL test SetLongTapDelay of |
|
140 * CAknLongTapDetector in aknlongtapdetector.h. |
|
141 * @since S60 5.0 |
|
142 * @param aItem is not used. |
|
143 * @return Symbian OS error code. |
|
144 */ |
|
145 virtual TInt TestCAknLongTapDetectorSetLongTapDelayL( CStifItemParser& aItem ); |
|
146 |
|
147 /** |
|
148 * TestCAknLongTapDetectorEnableLongTapAnimationL test EnableLongTapAnimation of |
|
149 * CAknLongTapDetector in aknlongtapdetector.h. |
|
150 * @since S60 5.0 |
|
151 * @param aItem is not used. |
|
152 * @return Symbian OS error code. |
|
153 */ |
|
154 virtual TInt TestCAknLongTapDetectorEnableLongTapAnimationL( CStifItemParser& aItem ); |
|
155 |
|
156 /** |
|
157 * TestCAknLongTapDetectorIsAnimationRunningL test IsAnimationRunning of |
|
158 * CAknLongTapDetector in aknlongtapdetector.h. |
|
159 * @since S60 5.0 |
|
160 * @param aItem is not used. |
|
161 * @return Symbian OS error code. |
|
162 */ |
|
163 virtual TInt TestCAknLongTapDetectorIsAnimationRunningL( CStifItemParser& aItem ); |
|
164 |
|
165 /** |
|
166 * TestCAknLongTapDetectorCancelAnimationL test CancelAnimationL of |
|
167 * CAknLongTapDetector in aknlongtapdetector.h. |
|
168 * @since S60 5.0 |
|
169 * @param aItem is not used. |
|
170 * @return Symbian OS error code. |
|
171 */ |
|
172 virtual TInt TestCAknLongTapDetectorCancelAnimationL( CStifItemParser& aItem ); |
|
173 |
|
174 /** |
|
175 * TestCAknPointerSuppressorNewL test NewL of |
|
176 * CAknPointerEventSuppressor in aknpointereventsuppressor.h. |
|
177 * @since S60 5.0 |
|
178 * @param aItem is not used. |
|
179 * @return Symbian OS error code. |
|
180 */ |
|
181 virtual TInt TestCAknPointerSuppressorNewL( CStifItemParser& aItem ); |
|
182 |
|
183 /** |
|
184 * TestCAknPointerSuppressorSuppressPointerEventL test SuppressPointerEvent of |
|
185 * CAknPointerEventSuppressor in aknpointereventsuppressor.h. |
|
186 * @since S60 5.0 |
|
187 * @param aItem is not used. |
|
188 * @return Symbian OS error code. |
|
189 */ |
|
190 virtual TInt TestCAknPointerSuppressorSuppressPointerEventL( CStifItemParser& aItem ); |
|
191 |
|
192 /** |
|
193 * TestCAknPointerSuppressorSetMaxTapDurationL test SetMaxTapDuration of |
|
194 * CAknPointerEventSuppressor in aknpointereventsuppressor.h. |
|
195 * @since S60 5.0 |
|
196 * @param aItem is not used. |
|
197 * @return Symbian OS error code. |
|
198 */ |
|
199 virtual TInt TestCAknPointerSuppressorSetMaxTapDurationL( CStifItemParser& aItem ); |
|
200 |
|
201 /** |
|
202 * TestCAknPointerSuppressorSetMaxTapMoveL test SetMaxTapMove of |
|
203 * CAknPointerEventSuppressor in aknpointereventsuppressor.h. |
|
204 * @since S60 5.0 |
|
205 * @param aItem is not used. |
|
206 * @return Symbian OS error code. |
|
207 */ |
|
208 virtual TInt TestCAknPointerSuppressorSetMaxTapMoveL( CStifItemParser& aItem ); |
|
209 |
|
210 /** |
|
211 * TestCAknPointerSuppressorSetMinInterDragIntervalL test SetMinInterDragInterval of |
|
212 * CAknPointerEventSuppressor in aknpointereventsuppressor.h. |
|
213 * @since S60 5.0 |
|
214 * @param aItem is not used. |
|
215 * @return Symbian OS error code. |
|
216 */ |
|
217 virtual TInt TestCAknPointerSuppressorSetMinInterDragIntervalL( CStifItemParser& aItem ); |
|
218 |
|
219 private: // Data |
|
220 |
|
221 /** |
|
222 * ScreenSaver Property |
|
223 */ |
|
224 TInt iOldScreenSaverProperty; |
|
225 }; |
|
226 |
|
227 #endif // C_TESTSDKTOUCHUIUTIL_H |
|
228 |
|
229 // End of File |