1 /* |
|
2 * Copyright (c) 2005 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: The declaration for Shutdown Timer class of Location Settings |
|
15 * UI Server |
|
16 * |
|
17 */ |
|
18 |
|
19 |
|
20 #ifndef C_LOCSETTINGSUISRVSHUTDOWN_H |
|
21 #define C_LOCSETTINGSUISRVSHUTDOWN_H |
|
22 |
|
23 |
|
24 #include <e32std.h> |
|
25 #include <e32base.h> |
|
26 |
|
27 /** |
|
28 * The Server Shutdown Timer class. |
|
29 * |
|
30 * This class provides the timer functionality to shutdown the |
|
31 * Location Settings UI Server. |
|
32 * |
|
33 * @lib |
|
34 * @since S60 v3.1 |
|
35 */ |
|
36 NONSHARABLE_CLASS(CLocSettingsUISrvShutdown) : public CActive |
|
37 { |
|
38 public: |
|
39 /** |
|
40 * Symbian 2 Phase Constructor |
|
41 * |
|
42 * @since S60 v3.1 |
|
43 * @return A pointer to the created CLocSettingsUISrvShutdown |
|
44 * object |
|
45 */ |
|
46 static CLocSettingsUISrvShutdown* NewL(); |
|
47 |
|
48 /** |
|
49 * Destructor |
|
50 */ |
|
51 virtual ~CLocSettingsUISrvShutdown(); |
|
52 |
|
53 public: |
|
54 /** |
|
55 * Starts the Shutdown Timer. |
|
56 * Since it uses an Asynchronous Timer the callback will be |
|
57 * received in the RunL. |
|
58 * |
|
59 * @since S60 v3.1 |
|
60 */ |
|
61 void Start(); |
|
62 |
|
63 protected: // Functions from base class CActive |
|
64 |
|
65 /** |
|
66 * From CActive Handles asynchronous request completion. |
|
67 */ |
|
68 void RunL(); |
|
69 |
|
70 /** |
|
71 * From CActive Cancels any outstanding request. |
|
72 */ |
|
73 void DoCancel(); |
|
74 |
|
75 /** |
|
76 * From CActive Handles a leave in RunL. |
|
77 * |
|
78 * @param aError The RunL leave code. |
|
79 * @return Always KErrNone, because all errors are handled |
|
80 */ |
|
81 TInt RunError(TInt aError); |
|
82 |
|
83 private: |
|
84 /** |
|
85 * Constructor |
|
86 */ |
|
87 CLocSettingsUISrvShutdown(); |
|
88 |
|
89 /** |
|
90 * Symbian 2nd Phase Constructor |
|
91 * Leaves in case of Error. |
|
92 * |
|
93 * @since S60 v3.1 |
|
94 * @return None |
|
95 */ |
|
96 void ConstructL(); |
|
97 |
|
98 |
|
99 private: // data |
|
100 /** |
|
101 * The Timer object |
|
102 */ |
|
103 RTimer iTimer; |
|
104 }; |
|
105 |
|
106 #endif // C_LOCSETTINGSUISRVSHUTDOWN_H |
|