|
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 "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: Header file for the CCbsUiSettingsMonitor class. |
|
15 * |
|
16 * |
|
17 */ |
|
18 |
|
19 |
|
20 #ifndef CCBSUISETTINGSMONITOR_H |
|
21 #define CCBSUISETTINGSMONITOR_H |
|
22 |
|
23 // INCLUDES |
|
24 #include <e32base.h> |
|
25 |
|
26 #include <CbsCommon.h> |
|
27 |
|
28 |
|
29 // FORWARD DECLARATIONS |
|
30 class MCbs; |
|
31 class CCbsUiappAppUi; |
|
32 class MCbsUiSettingsObserver; |
|
33 |
|
34 // CLASS DEFINITIONS |
|
35 |
|
36 |
|
37 /** |
|
38 * Server notifies this class if settings are changed. |
|
39 * |
|
40 */ |
|
41 class CCbsUiSettingsMonitor : public CActive |
|
42 { |
|
43 public: // New functions |
|
44 /** |
|
45 * Create an instance of the class. |
|
46 * |
|
47 * @param aServer cbs server |
|
48 * @param aObserver settings observer |
|
49 */ |
|
50 static CCbsUiSettingsMonitor* NewL( |
|
51 MCbs& aServer , MCbsUiSettingsObserver& aObserver ); |
|
52 |
|
53 /** |
|
54 * Destructor. |
|
55 */ |
|
56 ~CCbsUiSettingsMonitor(); |
|
57 |
|
58 public: // From CActive |
|
59 |
|
60 /** |
|
61 * It is called when server notifies. |
|
62 */ |
|
63 void RunL(); |
|
64 |
|
65 /** |
|
66 * Cancels the request. |
|
67 */ |
|
68 void DoCancel(); |
|
69 |
|
70 private: // New functions |
|
71 |
|
72 /** |
|
73 * Issues the request.. |
|
74 */ |
|
75 void IssueRequest(); |
|
76 |
|
77 private: |
|
78 |
|
79 /** |
|
80 * Constructor. |
|
81 * |
|
82 * @param aServer cbs server |
|
83 */ |
|
84 CCbsUiSettingsMonitor( |
|
85 MCbs& aServer, MCbsUiSettingsObserver& aObserver ); |
|
86 |
|
87 /** |
|
88 * Finalizes the construction. |
|
89 */ |
|
90 void ConstructL(); |
|
91 |
|
92 private: // Data |
|
93 |
|
94 // ETrue if request is continued. |
|
95 TBool iContinue; |
|
96 |
|
97 // Server subsession for settings |
|
98 MCbs& iServer; |
|
99 |
|
100 // Event which is registered to server |
|
101 TCbsSettingsEvent iEvent; |
|
102 |
|
103 // Observer who is interested about settings changes. |
|
104 MCbsUiSettingsObserver& iObserver; |
|
105 }; |
|
106 |
|
107 #endif // CCBSUISETTINGSMONITOR_H |
|
108 |
|
109 |
|
110 // End of File |