33
|
1 |
/*
|
|
2 |
* Copyright (c) 2004-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: Active object to handle global list query results.
|
|
15 |
*
|
|
16 |
*/
|
|
17 |
|
|
18 |
|
|
19 |
#ifndef CAUIACTIVEOBJECT_H
|
|
20 |
#define CAUIACTIVEOBJECT_H
|
|
21 |
|
|
22 |
|
|
23 |
// INCLUDES
|
|
24 |
#include <e32base.h>
|
|
25 |
#include <badesca.h>
|
|
26 |
|
|
27 |
|
|
28 |
// DATA TYPES
|
|
29 |
typedef CArrayFixFlat<TInt> CCaUiTIntArray;
|
|
30 |
|
|
31 |
|
|
32 |
// FORWARD DECLARATIONS
|
|
33 |
class MCaUiReconnectQueryObserver;
|
|
34 |
class CCoeEnv;
|
|
35 |
class CPhCntFactory;
|
|
36 |
class CPhCntMatcher;
|
|
37 |
class CCaUiMessageSender;
|
|
38 |
|
|
39 |
// CLASS DECLARATION
|
|
40 |
|
|
41 |
/**
|
|
42 |
* Active object to handle global list query results.
|
|
43 |
*
|
|
44 |
* @lib CaUiEngine.lib
|
|
45 |
* @since 2.6
|
|
46 |
*/
|
|
47 |
NONSHARABLE_CLASS( CCaUiGlnActiveObject )
|
|
48 |
: public CActive
|
|
49 |
{
|
|
50 |
public: // Data types
|
|
51 |
|
|
52 |
/*
|
|
53 |
* The reconnect query options.
|
|
54 |
*/
|
|
55 |
enum TCaUiReconnectType
|
|
56 |
{
|
|
57 |
ECaUiVoiceCall = 0, // Voice call.
|
|
58 |
ECaUiVideoCall = 1, // Video call.
|
|
59 |
#ifdef RD_UNIFIED_EDITOR
|
|
60 |
ECaUiMsg = 2 // Unified editor.
|
|
61 |
#else // RD_UNIFIED_EDITOR
|
|
62 |
ECaUiMms = 2, // MMS.
|
|
63 |
ECaUiSms = 3 // SMS.
|
|
64 |
#endif // // RD_UNIFIED_EDITOR
|
|
65 |
};
|
|
66 |
|
|
67 |
|
|
68 |
/**
|
|
69 |
* The editor types that can be launched.
|
|
70 |
*
|
|
71 |
* ECaUiEditorSMS SMS editor.
|
|
72 |
* ECaUiEditorMMS MMS editor.
|
|
73 |
*/
|
|
74 |
enum TCaUiEditorType
|
|
75 |
{
|
|
76 |
#ifdef RD_UNIFIED_EDITOR
|
|
77 |
ECaUiEditorMSG = 0
|
|
78 |
#else // RD_UNIFIED_EDITOR
|
|
79 |
ECaUiEditorSMS = 0,
|
|
80 |
ECaUiEditorMMS = 1
|
|
81 |
#endif // RD_UNIFIED_EDITOR
|
|
82 |
};
|
|
83 |
|
|
84 |
public: // Constructors and destructor
|
|
85 |
|
|
86 |
/**
|
|
87 |
* Two-phased constructor.
|
|
88 |
*
|
|
89 |
* @param aObserver The observer to handle query results.
|
|
90 |
* @param aPhCntMatcher The Phone Contact Matcher.
|
|
91 |
* Ownership not transferred. If NULL, then matcher is created
|
|
92 |
* inside CCaUiGlnActiveObject.
|
|
93 |
* @param aPhoneNumber Pointer to the number where dial was tried.
|
|
94 |
* @param aAlias The alias corresponding the number. Can be NULL.
|
|
95 |
* @return Constructed CCaUiGlnActiveObject instance.
|
|
96 |
*/
|
|
97 |
static CCaUiGlnActiveObject* NewL(
|
|
98 |
MCaUiReconnectQueryObserver& aObserver,
|
|
99 |
CPhCntMatcher* aPhCntMatcher,
|
|
100 |
const TPtrC aPhoneNumber,
|
|
101 |
const TPtrC aAlias );
|
|
102 |
|
|
103 |
/**
|
|
104 |
* Destructor.
|
|
105 |
*/
|
|
106 |
virtual ~CCaUiGlnActiveObject();
|
|
107 |
|
|
108 |
|
|
109 |
public: // New functions
|
|
110 |
|
|
111 |
|
|
112 |
/**
|
|
113 |
* Returns reconnect query options array, that must include options
|
|
114 |
* in the same order and in the same locations than they are in
|
|
115 |
* reconnect query. Insert only TCaUiReconnectType members.
|
|
116 |
*
|
|
117 |
* @return Reconnect query options array.
|
|
118 |
*/
|
|
119 |
CCaUiTIntArray* ReconQueryOptionsArray();
|
|
120 |
|
|
121 |
|
|
122 |
public: // Functions from base classes
|
|
123 |
|
|
124 |
/**
|
|
125 |
* @see CActive::DoCancel.
|
|
126 |
*/
|
|
127 |
void DoCancel();
|
|
128 |
|
|
129 |
/**
|
|
130 |
* @see CActive::RunL.
|
|
131 |
*/
|
|
132 |
void RunL();
|
|
133 |
|
|
134 |
|
|
135 |
/**
|
|
136 |
* @see CActive::SetActive.
|
|
137 |
*/
|
|
138 |
void SetActive();
|
|
139 |
|
|
140 |
|
|
141 |
private:
|
|
142 |
|
|
143 |
/**
|
|
144 |
* C++ constructor.
|
|
145 |
*
|
|
146 |
* @param aObserver The observer to handle query results.
|
|
147 |
*/
|
|
148 |
CCaUiGlnActiveObject(
|
|
149 |
MCaUiReconnectQueryObserver& aObserver );
|
|
150 |
|
|
151 |
/**
|
|
152 |
* By default Symbian 2nd phase constructor is private.
|
|
153 |
*
|
|
154 |
* @see CCaUiGlnActiveObject::NewL().
|
|
155 |
*/
|
|
156 |
void ConstructL(
|
|
157 |
CPhCntMatcher* aPhCntMatcher,
|
|
158 |
const TPtrC aPhoneNumber,
|
|
159 |
const TPtrC aAlias );
|
|
160 |
|
|
161 |
|
|
162 |
/**
|
|
163 |
* Launch the desired editor.
|
|
164 |
*
|
|
165 |
* @param aEditorType The editor type to be launched.
|
|
166 |
*/
|
|
167 |
void LaunchEditorL( TCaUiEditorType aEditorType );
|
|
168 |
|
|
169 |
/**
|
|
170 |
* Creates message sender.
|
|
171 |
*
|
|
172 |
*/
|
|
173 |
void CreateMessageSenderL();
|
|
174 |
|
|
175 |
private: // Data
|
|
176 |
|
|
177 |
|
|
178 |
// The query observer.
|
|
179 |
MCaUiReconnectQueryObserver* iObserver;
|
|
180 |
|
|
181 |
// Storage for real addresses.
|
|
182 |
CDesCArrayFlat* iRealAddress;
|
|
183 |
|
|
184 |
// Storage for aliases.
|
|
185 |
CDesCArrayFlat* iAliases;
|
|
186 |
|
|
187 |
// Storage for reconnect query options.
|
|
188 |
CCaUiTIntArray* iReConQueryOptions;
|
|
189 |
|
|
190 |
// Phone Contact finder factory.
|
|
191 |
CPhCntFactory* iPhCntFactory;
|
|
192 |
|
|
193 |
// Phone Contact matcher.
|
|
194 |
CPhCntMatcher* iPhCntMatcher;
|
|
195 |
|
|
196 |
// Is CPhCntMatcher owned.
|
|
197 |
TBool iOwnMatcher;
|
|
198 |
|
|
199 |
// Message sender
|
|
200 |
CCaUiMessageSender* iMessageSender;
|
|
201 |
|
|
202 |
};
|
|
203 |
|
|
204 |
/**
|
|
205 |
* Active object to handle note results.
|
|
206 |
*
|
|
207 |
* @lib CaUiEngine.lib
|
|
208 |
* @since 2.6
|
|
209 |
*/
|
|
210 |
NONSHARABLE_CLASS( CCaUiNoteActiveObject )
|
|
211 |
: public CActive
|
|
212 |
{
|
|
213 |
public: // Constructors and destructor
|
|
214 |
|
|
215 |
/**
|
|
216 |
* Two-phased constructor.
|
|
217 |
*
|
|
218 |
* @return Constructed CCaUiNoteActiveObject instance.
|
|
219 |
*/
|
|
220 |
static CCaUiNoteActiveObject* NewL();
|
|
221 |
|
|
222 |
/**
|
|
223 |
* Destructor.
|
|
224 |
*/
|
|
225 |
virtual ~CCaUiNoteActiveObject();
|
|
226 |
|
|
227 |
|
|
228 |
|
|
229 |
public: // Functions from base classes
|
|
230 |
|
|
231 |
/**
|
|
232 |
* @see CActive::DoCancel.
|
|
233 |
*/
|
|
234 |
void DoCancel();
|
|
235 |
|
|
236 |
/**
|
|
237 |
* @see CActive::RunL.
|
|
238 |
*/
|
|
239 |
void RunL();
|
|
240 |
|
|
241 |
/**
|
|
242 |
* @see CActive::SetActive.
|
|
243 |
*/
|
|
244 |
void SetActive();
|
|
245 |
|
|
246 |
|
|
247 |
private:
|
|
248 |
|
|
249 |
/**
|
|
250 |
* C++ default constructor.
|
|
251 |
*
|
|
252 |
*/
|
|
253 |
CCaUiNoteActiveObject();
|
|
254 |
};
|
|
255 |
|
|
256 |
#endif // CCAUIACTIVEOBJECT_H
|
|
257 |
|
|
258 |
// End of File
|