37
|
1 |
/*
|
|
2 |
* Copyright (c) 2007-2008 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: Implementation of CPhoneResolverVoIP class.
|
|
15 |
*
|
|
16 |
*/
|
|
17 |
|
|
18 |
|
|
19 |
// INCLUDE FILES
|
|
20 |
#include <bautils.h>
|
|
21 |
#include <AknUtils.h>
|
|
22 |
#include "phoneresourceids.h"
|
|
23 |
#include <data_caging_path_literals.hrh>
|
|
24 |
#include "cphoneresourceresolvervoip.h"
|
|
25 |
#include "cphonemainresourceresolver.h"
|
|
26 |
#include "phonerssvoip.h"
|
|
27 |
|
|
28 |
// ============================ MEMBER FUNCTIONS ===============================
|
|
29 |
|
|
30 |
// -----------------------------------------------------------------------------
|
|
31 |
// CPhoneResourceResolverVoIP::CPhoneResourceResolverVoIP
|
|
32 |
// C++ default constructor can NOT contain any code, that
|
|
33 |
// might leave.
|
|
34 |
// -----------------------------------------------------------------------------
|
|
35 |
//
|
|
36 |
CPhoneResourceResolverVoIP::CPhoneResourceResolverVoIP()
|
|
37 |
{
|
|
38 |
}
|
|
39 |
|
|
40 |
// -----------------------------------------------------------------------------
|
|
41 |
// CPhoneRourceResolverVoIP::ConstructL
|
|
42 |
// Symbian 2nd phase constructor can leave.
|
|
43 |
// -----------------------------------------------------------------------------
|
|
44 |
//
|
|
45 |
void CPhoneResourceResolverVoIP::ConstructL()
|
|
46 |
{
|
|
47 |
// Register resolver
|
|
48 |
CPhoneMainResourceResolver::Instance()->RegisterResolver( this );
|
|
49 |
}
|
|
50 |
|
|
51 |
// -----------------------------------------------------------------------------
|
|
52 |
// CPhoneResourceResolverVoIP::NewL
|
|
53 |
// Two-phased constructor.
|
|
54 |
// -----------------------------------------------------------------------------
|
|
55 |
//
|
|
56 |
CPhoneResourceResolverVoIP* CPhoneResourceResolverVoIP::NewL()
|
|
57 |
{
|
|
58 |
CPhoneResourceResolverVoIP* self =
|
|
59 |
new( ELeave ) CPhoneResourceResolverVoIP();
|
|
60 |
CleanupStack::PushL( self );
|
|
61 |
self->ConstructL();
|
|
62 |
CleanupStack::Pop( self );
|
|
63 |
return self;
|
|
64 |
}
|
|
65 |
|
|
66 |
// Destructor
|
|
67 |
CPhoneResourceResolverVoIP::~CPhoneResourceResolverVoIP()
|
|
68 |
{
|
|
69 |
}
|
|
70 |
|
|
71 |
// -----------------------------------------------------------------------------
|
|
72 |
// CPhoneResourceResolverVoIP::ResolveResourceID
|
|
73 |
// Resolve resource id of given resource.
|
|
74 |
// (other items were commented in a header).
|
|
75 |
// -----------------------------------------------------------------------------
|
|
76 |
//
|
|
77 |
TInt CPhoneResourceResolverVoIP::ResolveResourceID(
|
|
78 |
const TInt& aResource ) const
|
|
79 |
{
|
|
80 |
TInt retVal( KErrNotFound );
|
|
81 |
|
|
82 |
switch( aResource )
|
|
83 |
{
|
|
84 |
case EPhoneVoIPNumberAcqMenubar:
|
|
85 |
retVal = R_PHONEUI_NUMBERACQ_MENUBAR_VOIP;
|
|
86 |
break;
|
|
87 |
|
|
88 |
case EPhoneVoIPNumberAcqMenubarWithServiceNumber:
|
|
89 |
retVal = R_PHONEUI_NUMBERACQ_MENUBAR_VOIP_WITH_SERVICE_NUMBER;
|
|
90 |
break;
|
|
91 |
|
|
92 |
case EPhoneVoIPNumberAcqOkMenubar:
|
|
93 |
retVal = R_PHONEUI_NUMBERACQ_OK_MENUBAR_VOIP;
|
|
94 |
break;
|
|
95 |
|
|
96 |
case EPhoneVoIPNumberAcqOkMenubarWithServiceNumber:
|
|
97 |
retVal = R_PHONEUI_NUMBERACQ_OK_MENUBAR_VOIP_WITH_SERVICE_NUMBER;
|
|
98 |
break;
|
|
99 |
|
|
100 |
case EPhoneVoIPNumberAcqInternetSoftkey:
|
|
101 |
retVal = R_PHONEUI_NUMBERACQ_INTERNETCALL_CBA;
|
|
102 |
break;
|
|
103 |
|
|
104 |
case EPhoneVoIPPrivateAddress:
|
|
105 |
retVal = R_PHONEUI_VOIP_PRIVATE_ADDRESS;
|
|
106 |
break;
|
|
107 |
|
|
108 |
case EPhoneVoIPNoAudioSupport:
|
|
109 |
retVal = R_PHONE_VOIP_NO_AUDIO_SUPPORT;
|
|
110 |
break;
|
|
111 |
|
|
112 |
case EPhoneVoIPNoService:
|
|
113 |
retVal = R_PHONE_VOIP_NO_VOIP_SERVICE_ERROR;
|
|
114 |
break;
|
|
115 |
|
|
116 |
case EPhoneRemoteForwarding:
|
|
117 |
retVal = R_PHONE_VOIP_CALL_BEING_FORWARDED;
|
|
118 |
break;
|
|
119 |
|
|
120 |
case EPhoneVoIPServiceUnavailable:
|
|
121 |
retVal = R_NO_SERVICE_AVAILABLE_INFO;
|
|
122 |
break;
|
|
123 |
|
|
124 |
case EPhoneVoIPAddressNotInUse:
|
|
125 |
retVal = R_PHONE_VOIP_ADDRESS_NOT_IN_USE;
|
|
126 |
break;
|
|
127 |
|
|
128 |
case EPhoneVoIPRequestTimeOut:
|
|
129 |
retVal = R_PHONE_VOIP_REQUEST_TIME_OUT;
|
|
130 |
break;
|
|
131 |
|
|
132 |
case EPhoneVoIPInvalidRecipientAddress:
|
|
133 |
retVal = R_PHONE_VOIP_INVALID_RECIPIENT_ADDRESS;
|
|
134 |
break;
|
|
135 |
|
|
136 |
case EPhoneVoIPNumberBusy:
|
|
137 |
retVal = R_PHONE_VOIP_NUMBER_BUSY;
|
|
138 |
break;
|
|
139 |
|
|
140 |
case EPhoneVoIPNotFound:
|
|
141 |
retVal = R_PHONE_VOIP_NOT_FOUND;
|
|
142 |
break;
|
|
143 |
|
|
144 |
case EPhoneVoIPNoAnswer:
|
|
145 |
retVal = R_PHONE_VOIP_NO_ANSWER;
|
|
146 |
break;
|
|
147 |
|
|
148 |
case EPhoneSSNotificationTextVoipSipsFailed:
|
|
149 |
retVal = R_PHONE_SS_NOTIFICATION_TEXT_VOIP_SIPS_FAILED;
|
|
150 |
break;
|
|
151 |
|
|
152 |
case EPhoneVoIPNetworkError:
|
|
153 |
retVal = R_VOIP_NETWORK_ERROR_NOTE;
|
|
154 |
break;
|
|
155 |
|
|
156 |
case EPhoneVoIPHoldFail:
|
|
157 |
retVal = R_VOIP_HOLD_FAILED;
|
|
158 |
break;
|
|
159 |
|
|
160 |
case EPhoneVoIPHoldNumberFail:
|
|
161 |
retVal = R_VOIP_HOLD_NUMBER_FAILED;
|
|
162 |
break;
|
|
163 |
|
|
164 |
case EPhoneVoIPResumeFail:
|
|
165 |
retVal = R_VOIP_RESUME_FAILED;
|
|
166 |
break;
|
|
167 |
|
|
168 |
case EPhoneVoIPResumeNumberFail:
|
|
169 |
retVal = R_VOIP_RESUME_NUMBER_FAILED;
|
|
170 |
break;
|
|
171 |
|
|
172 |
case EPhoneVoIPSwapFail:
|
|
173 |
retVal = R_VOIP_SWAP_FAILED;
|
|
174 |
break;
|
|
175 |
|
|
176 |
case EPhoneVoIPConferenceHoldFail:
|
|
177 |
retVal = R_VOIP_CONFERENCE_HOLD_FAILED;
|
|
178 |
break;
|
|
179 |
|
|
180 |
case EPhoneVoIPConferenceResumeFail:
|
|
181 |
retVal = R_VOIP_CONFERENCE_RESUME_FAILED;
|
|
182 |
break;
|
|
183 |
|
|
184 |
case EPhoneVoIPTransferFail:
|
|
185 |
retVal = R_VOIP_TRANSFER_FAILED_NOTE;
|
|
186 |
break;
|
|
187 |
case EPhoneVoIPWaitingAcceptanceNote:
|
|
188 |
retVal = R_VOIP_TRANSFER_WAITING_ACCEPTENCE;
|
|
189 |
break;
|
|
190 |
case EPhoneVoIPCallTypeInternet:
|
|
191 |
retVal = R_VOIP_CALL_TYPE_INTERNET;
|
|
192 |
break;
|
|
193 |
case EPhoneVoIPNumberAcqXSPCall:
|
|
194 |
break;
|
|
195 |
case EPhoneVoIPUnattendedTransferOption:
|
|
196 |
retVal = R_VOIP_UNATTENDED_TRANSFER_OPTION;
|
|
197 |
break;
|
|
198 |
case EPhoneVoIPUnattendedTransferAcceptanceQueryIdentified:
|
|
199 |
retVal = R_PHONE_VOIP_TRANSFER_ACCEPT;
|
|
200 |
break;
|
|
201 |
case EPhoneVoIPUnattendedTransferAcceptanceQueryAnonymous:
|
|
202 |
retVal = R_PHONE_VOIP_TRANSFER_ACCEPT_CLI;
|
|
203 |
break;
|
|
204 |
case EPhoneVoIPUnattendedTransferAcceptanceQueryHeader:
|
|
205 |
retVal = R_PHONE_VOIP_QUERY_ACC_ID_HEADER;
|
|
206 |
break;
|
|
207 |
case EPhoneVoIPTransferAddress:
|
|
208 |
retVal = R_VOIP_TRANSFER_ADDRESS;
|
|
209 |
break;
|
|
210 |
case EPhoneVoIPTransferDialerNumberEntryEmptyMenubar:
|
|
211 |
retVal = R_PHONEUIDIALER_NUMBERENTRY_EMPTY_TRANSFER_MENUBAR;
|
|
212 |
break;
|
|
213 |
case EPhoneVoIPTransferDialerNumberEntryNotEmptyMenubar:
|
|
214 |
retVal = R_PHONEUIDIALER_NUMBERENTRY_NOT_EMPTY_TRANSFER_MENUBAR;
|
|
215 |
break;
|
|
216 |
case EPhoneVoIPTransferDialerSoftkeys:
|
|
217 |
retVal = R_PHONEUI_TRANSFER_DIALER_SOFTKEYS_OPTIONS_CANCEL;
|
|
218 |
break;
|
|
219 |
case EPhoneVoIPTransferAddressQuery:
|
|
220 |
retVal = R_PHONE_TRANSFER_VOIP_CALL_QUERY;
|
|
221 |
break;
|
|
222 |
case EPhoneVoIPTransferAddressQueryEmptySoftkeys:
|
|
223 |
retVal = R_PHONE_VOIP_SOFTKEYS_SEARCH_CANCEL;
|
|
224 |
break;
|
|
225 |
case EPhoneVoIPTransferAddressQueryNotEmptySoftkeys:
|
|
226 |
retVal = R_PHONE_VOIP_SOFTKEYS_OK_CANCEL;
|
|
227 |
break;
|
|
228 |
case EPhoneVoIPNewCallQuery:
|
|
229 |
retVal = R_PHONE_NEW_VOIP_CALL_QUERY;
|
|
230 |
break;
|
|
231 |
case EPhoneVoIPNewCallQueryEmptySoftkeys:
|
|
232 |
retVal = R_PHONE_NEW_VOIP_CALL_SOFTKEYS_SEARCH_CANCEL;
|
|
233 |
break;
|
|
234 |
case EPhoneVoIPNewCallQueryNotEmptySoftkeys:
|
|
235 |
retVal = R_PHONE_VOIP_NEW_CALL_SOFTKEYS_OK_CANCEL;
|
|
236 |
break;
|
|
237 |
case EPhoneVoIPEnablingServiceWaitNoteText:
|
|
238 |
retVal = R_PHONE_VOIP_CONNECTING_SERVICE;
|
|
239 |
break;
|
|
240 |
case EPhoneVoIPAuthenticationFailed:
|
|
241 |
retVal = R_PHONEUI_VOIP_ERROR_NOTE_AUTHENTICATION_FAILED;
|
|
242 |
break;
|
|
243 |
case EPhoneVoIPHandoverToWlanOption:
|
|
244 |
retVal = R_VOIP_HANDOVER_TO_WLAN_OPTION;
|
|
245 |
break;
|
|
246 |
case EPhoneVoIPHandoverToGsmOption:
|
|
247 |
retVal = R_VOIP_HANDOVER_TO_GSM_OPTION;
|
|
248 |
break;
|
|
249 |
case EPhoneVoIPNewCallMenuOption:
|
|
250 |
retVal = R_PHONE_VOIP_NEW_CALL_OPTION;
|
|
251 |
break;
|
|
252 |
case EPhoneVoIPErrorInConnection:
|
|
253 |
retVal = R_PHONEUI_VOIP_ERROR_IN_CONNECTION;
|
|
254 |
break;
|
|
255 |
case EPhoneVoIPWaitHandoverFromWlan:
|
|
256 |
retVal = R_VOIP_VCC_WAIT_HO_FROM_WLAN;
|
|
257 |
break;
|
|
258 |
case EPhoneVoIPWaitHandoverFromGsm:
|
|
259 |
retVal = R_VOIP_VCC_WAIT_HO_FROM_GSM;
|
|
260 |
break;
|
|
261 |
case EPhoneVoIPHandoverFail:
|
|
262 |
retVal = R_VOIP_VCC_INFO_HO_FAILED;
|
|
263 |
break;
|
|
264 |
case EPhoneVoIPMovedPermanentlyQueryHeader:
|
|
265 |
retVal = R_PHONEUI_VOIP_QUERY_HEADER_MOVED_PERMANENTLY;
|
|
266 |
break;
|
|
267 |
case EPhoneVoIPMovedPermanentlySoftkeys:
|
|
268 |
//retVal = R_PHONE_VOIP_SOFTKEYS_OK_END_CALL;
|
|
269 |
retVal = R_AVKON_SOFTKEYS_OK_CANCEL;
|
|
270 |
break;
|
|
271 |
case EPhoneVoIPMultipleChoicesListQuery:
|
|
272 |
retVal = R_PHONE_VOIP_MULTIPLE_CHOICES_LIST_QUERY;
|
|
273 |
break;
|
|
274 |
case EPhoneVoIPNoConnectionsDefined:
|
|
275 |
retVal = R_PHONE_VOIP_NO_CONNECTIONS_DEFINED;
|
|
276 |
break;
|
|
277 |
case EPhoneVoIPNoConnectionsAvailable:
|
|
278 |
retVal = R_PHONE_VOIP_NO_CONNECTIONS_AVAILABLE;
|
|
279 |
break;
|
|
280 |
case EPhoneVoIPCallsNotSupported:
|
|
281 |
retVal = R_PHONE_VOIP_CONNECTION_DOES_NOT_SUPPORT_CALLS;
|
|
282 |
break;
|
|
283 |
case EPhoneVoIPNotAvailableWhenConnecting:
|
|
284 |
retVal = R_PHONE_VOIP_CONNECTION_NOT_AVAILABLE_DURING_ALR;
|
|
285 |
break;
|
|
286 |
case EPhoneVoIPDefectiveSettings:
|
|
287 |
retVal = R_PHONE_VOIP_CREATING_CONN_FAILED_PERMANENTLY;
|
|
288 |
break;
|
|
289 |
default:
|
|
290 |
retVal = CPhoneResourceResolverGSM::ResolveResourceID( aResource );
|
|
291 |
break;
|
|
292 |
}
|
|
293 |
|
|
294 |
return retVal;
|
|
295 |
}
|
|
296 |
|
|
297 |
// End of File
|