author | Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com> |
Wed, 18 Aug 2010 09:48:26 +0300 | |
changeset 56 | 5bcb308bd24d |
parent 37 | ba76fc04e6c2 |
child 65 | 2a5d4ab426d3 |
permissions | -rw-r--r-- |
37 | 1 |
/* |
2 |
* Copyright (c) 2005-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 CPhoneConferenceAndWaiting class. |
|
15 |
* |
|
16 |
*/ |
|
17 |
||
18 |
||
19 |
// INCLUDES |
|
20 |
#include <StringLoader.h> |
|
21 |
#include <cpephonemodelif.h> |
|
22 |
#include <featmgr.h> |
|
23 |
#include <telephonyvariant.hrh> |
|
24 |
#include "cphoneconferenceandwaiting.h" |
|
25 |
#include "mphonestatemachine.h" |
|
26 |
#include "phoneviewcommanddefinitions.h" |
|
27 |
#include "tphonecmdparamcallheaderdata.h" |
|
28 |
#include "phonestatedefinitionsgsm.h" |
|
29 |
#include "phonelogger.h" |
|
30 |
#include "tphonecmdparamboolean.h" |
|
31 |
#include "tphonecmdparaminteger.h" |
|
32 |
#include "tphonecmdparamcallstatedata.h" |
|
33 |
#include "cphonemainresourceresolver.h" |
|
34 |
#include "phonerssbase.h" |
|
35 |
#include "tphonecmdparamglobalnote.h" |
|
36 |
#include "phoneui.hrh" |
|
37 |
#include "cphonecenrepproxy.h" |
|
38 |
#include "mphonestorage.h" |
|
39 |
||
40 |
// ================= MEMBER FUNCTIONS ======================= |
|
41 |
||
42 |
// C++ default constructor can NOT contain any code, that |
|
43 |
// might leave. |
|
44 |
// |
|
45 |
CPhoneConferenceAndWaiting::CPhoneConferenceAndWaiting( |
|
46 |
MPhoneStateMachine* aStateMachine, |
|
47 |
MPhoneViewCommandHandle* aViewCommandHandle, |
|
48 |
MPhoneCustomization* aPhoneCustomization ) : |
|
49 |
CPhoneConference( aStateMachine, aViewCommandHandle, aPhoneCustomization ) |
|
50 |
{ |
|
51 |
} |
|
52 |
||
53 |
// ----------------------------------------------------------- |
|
54 |
// CPhoneConferenceAndWaiting::~CPhoneConferenceAndWaiting() |
|
55 |
// Destructor |
|
56 |
// (other items were commented in a header). |
|
57 |
// ----------------------------------------------------------- |
|
58 |
// |
|
59 |
CPhoneConferenceAndWaiting::~CPhoneConferenceAndWaiting() |
|
60 |
{ |
|
61 |
} |
|
62 |
||
63 |
// ----------------------------------------------------------- |
|
64 |
// CPhoneConferenceAndWaiting::ConstructL() |
|
65 |
// Constructor |
|
66 |
// (other items were commented in a header). |
|
67 |
// ----------------------------------------------------------- |
|
68 |
// |
|
69 |
void CPhoneConferenceAndWaiting::ConstructL() |
|
70 |
{ |
|
71 |
CPhoneConference::ConstructL(); |
|
72 |
||
73 |
// Fetch ringing call's id from view |
|
74 |
TPhoneCmdParamCallStateData callStateData; |
|
75 |
callStateData.SetCallState( EPEStateRinging ); |
|
76 |
iViewCommandHandle->HandleCommandL( |
|
77 |
EPhoneViewGetCallIdByState, &callStateData ); |
|
78 |
iRingingCallId = callStateData.CallId(); |
|
79 |
} |
|
80 |
||
81 |
// ----------------------------------------------------------- |
|
82 |
// CPhoneConferenceAndWaiting::NewL() |
|
83 |
// Constructor |
|
84 |
// (other items were commented in a header). |
|
85 |
// ----------------------------------------------------------- |
|
86 |
// |
|
87 |
CPhoneConferenceAndWaiting* CPhoneConferenceAndWaiting::NewL( |
|
88 |
MPhoneStateMachine* aStateMachine, |
|
89 |
MPhoneViewCommandHandle* aViewCommandHandle, |
|
90 |
MPhoneCustomization* aPhoneCustomization ) |
|
91 |
{ |
|
92 |
CPhoneConferenceAndWaiting* self = new( ELeave ) CPhoneConferenceAndWaiting( |
|
93 |
aStateMachine, aViewCommandHandle, aPhoneCustomization ); |
|
94 |
||
95 |
CleanupStack::PushL( self ); |
|
96 |
self->ConstructL(); |
|
97 |
CleanupStack::Pop( self ); |
|
98 |
||
99 |
return self; |
|
100 |
} |
|
101 |
||
102 |
// ----------------------------------------------------------- |
|
103 |
// CPhoneConferenceAndWaiting::HandlePhoneEngineMessageL |
|
104 |
// ----------------------------------------------------------- |
|
105 |
// |
|
106 |
void CPhoneConferenceAndWaiting::HandlePhoneEngineMessageL( |
|
107 |
const TInt aMessage, |
|
108 |
TInt aCallId ) |
|
109 |
{ |
|
110 |
__LOGMETHODSTARTEND( EPhoneUIStates, "CPhoneConferenceAndWaiting::HandlePhoneEngineMessageL()"); |
|
111 |
switch ( aMessage ) |
|
112 |
{ |
|
113 |
case MEngineMonitor::EPEMessageIdle: |
|
114 |
HandleIdleL( aCallId ); |
|
115 |
break; |
|
116 |
||
117 |
case MEngineMonitor::EPEMessageConnected: |
|
118 |
HandleConnectedL( aCallId ); |
|
119 |
break; |
|
120 |
||
121 |
case MEngineMonitor::EPEMessageDialing: |
|
122 |
HandleDiallingL( aCallId ); |
|
123 |
break; |
|
124 |
||
125 |
case MEngineMonitor::EPEMessageConferenceIdle: |
|
126 |
HandleConferenceIdleL(); |
|
127 |
break; |
|
128 |
||
129 |
case MEngineMonitor::EPEMessageWentOneToOne: |
|
130 |
HandleWentOneToOneL( aCallId ); |
|
131 |
break; |
|
132 |
||
133 |
case MEngineMonitor::EPEMessageHeldConference: |
|
134 |
case MEngineMonitor::EPEMessageConnectedConference: |
|
135 |
{ |
|
136 |
TPhoneCmdParamInteger callIdParam; |
|
137 |
iViewCommandHandle->ExecuteCommandL( |
|
138 |
EPhoneViewGetExpandedBubbleCallId, &callIdParam ); |
|
139 |
||
140 |
CPhoneConference::HandlePhoneEngineMessageL( aMessage, |
|
141 |
aCallId ); |
|
142 |
||
143 |
if ( KConferenceCallId == callIdParam.Integer() ) |
|
144 |
{ |
|
145 |
iViewCommandHandle->ExecuteCommand(EPhoneSetConferenceExpanded); |
|
146 |
} |
|
147 |
} |
|
148 |
break; |
|
149 |
||
150 |
default: |
|
151 |
CPhoneConference::HandlePhoneEngineMessageL( aMessage, |
|
152 |
aCallId ); |
|
153 |
break; |
|
154 |
} |
|
155 |
} |
|
156 |
||
157 |
// -------------------------------------------------------------- |
|
158 |
// CPhoneConferenceAndWaiting::HandleKeyMessageL |
|
159 |
// -------------------------------------------------------------- |
|
160 |
// |
|
161 |
void CPhoneConferenceAndWaiting::HandleKeyMessageL( |
|
162 |
TPhoneKeyEventMessages aMessage, |
|
163 |
TKeyCode aCode ) |
|
164 |
{ |
|
165 |
__LOGMETHODSTARTEND(EPhoneUIStates, "CPhoneConferenceAndWaiting::HandleKeyMessageL()"); |
|
166 |
switch ( aCode ) |
|
167 |
{ |
|
168 |
// send-key |
|
169 |
case EKeyYes: |
|
170 |
if( IsNumberEntryVisibleL() ) |
|
171 |
{ |
|
172 |
CallFromNumberEntryL(); |
|
173 |
} |
|
174 |
else |
|
175 |
{ |
|
176 |
// Number entry is below incoming call bubble so |
|
177 |
// answer the call |
|
178 |
iStateMachine->SendPhoneEngineMessage( |
|
179 |
MPEPhoneModel::EPEMessageAnswer ); |
|
180 |
} |
|
181 |
break; |
|
182 |
||
183 |
default: |
|
184 |
// do base operation |
|
185 |
CPhoneConference::HandleKeyMessageL( aMessage, aCode ); |
|
186 |
break; |
|
187 |
} |
|
188 |
} |
|
189 |
||
190 |
// ----------------------------------------------------------- |
|
191 |
// CPhoneConferenceAndWaiting::HandleKeyEventL |
|
192 |
// ----------------------------------------------------------- |
|
193 |
// |
|
194 |
void CPhoneConferenceAndWaiting::HandleKeyEventL( |
|
195 |
const TKeyEvent& aKeyEvent, |
|
196 |
TEventCode /*aEventCode*/ ) |
|
197 |
{ |
|
198 |
if( EKeyDeviceF == aKeyEvent.iCode ) |
|
199 |
{ |
|
200 |
__PHONELOG( EBasic, EPhoneUIStates, |
|
201 |
"CPhoneConferenceAndWaiting::HandleKeyMessageL-deviceF" ); |
|
202 |
HandleHoldSwitchL(); |
|
203 |
} |
|
204 |
} |
|
205 |
||
206 |
// ----------------------------------------------------------- |
|
207 |
// CPhoneConferenceAndWaiting::HandleConnectedL |
|
208 |
// ----------------------------------------------------------- |
|
209 |
// |
|
210 |
void CPhoneConferenceAndWaiting::HandleConnectedL( TInt aCallId ) |
|
211 |
{ |
|
212 |
__LOGMETHODSTARTEND(EPhoneUIStates, "CPhoneConferenceAndWaiting::HandleConnectedL()"); |
|
213 |
TPhoneCmdParamCallStateData callStateData; |
|
214 |
||
215 |
if ( iRingingCallId == KErrNotFound ) |
|
216 |
{ |
|
217 |
// Fetch ringing call's id from view |
|
218 |
TPhoneCmdParamCallStateData callStateData; |
|
219 |
callStateData.SetCallState( EPEStateRinging ); |
|
220 |
iViewCommandHandle->HandleCommandL( |
|
221 |
EPhoneViewGetCallIdByState, &callStateData ); |
|
222 |
iRingingCallId = callStateData.CallId(); |
|
223 |
} |
|
224 |
||
225 |
if ( iRingingCallId == aCallId ) |
|
226 |
{ |
|
227 |
// not a member of conference call |
|
228 |
MakeStateTransitionToConferenceAndSingleL( aCallId ); |
|
229 |
} |
|
230 |
else |
|
231 |
{ |
|
232 |
// member of conference call which is on hold |
|
233 |
TPhoneCmdParamCallHeaderData callHeaderParam; |
|
234 |
callHeaderParam.SetCallState( EPEStateConnected ); |
|
235 |
iViewCommandHandle->ExecuteCommandL( EPhoneViewUpdateBubble, aCallId, |
|
236 |
&callHeaderParam ); |
|
237 |
} |
|
238 |
} |
|
239 |
||
240 |
// ----------------------------------------------------------- |
|
241 |
// CPhoneConferenceAndWaiting::MakeStateTransitionToConferenceAndSingleL |
|
242 |
// ----------------------------------------------------------- |
|
243 |
// |
|
244 |
void CPhoneConferenceAndWaiting::MakeStateTransitionToConferenceAndSingleL( TInt aCallId ) |
|
245 |
{ |
|
246 |
__LOGMETHODSTARTEND(EPhoneUIStates, "CPhoneConferenceAndWaiting::MakeStateTransitionToConferenceAndSingleL()"); |
|
247 |
||
248 |
if( FeatureManager::FeatureSupported( KFeatureIdFfTouchUnlockStroke ) |
|
249 |
&& iStateMachine->PhoneStorage()->IsScreenLocked() ) |
|
250 |
{ |
|
251 |
EnableCallUIL(); |
|
252 |
} |
|
253 |
||
254 |
// Reset blocked keys list |
|
255 |
iStateMachine->PhoneStorage()->ResetBlockedKeysList(); |
|
256 |
||
257 |
BeginUiUpdateLC(); |
|
258 |
||
259 |
UpdateRemoteInfoDataL ( aCallId ); |
|
260 |
||
261 |
// Show bubble |
|
262 |
TPhoneCmdParamCallHeaderData callHeaderParam; |
|
263 |
callHeaderParam.SetCallState( EPEStateConnected ); |
|
264 |
iViewCommandHandle->ExecuteCommandL( EPhoneViewUpdateBubble, aCallId, |
|
265 |
&callHeaderParam ); |
|
266 |
||
267 |
||
268 |
if ( IsNumberEntryUsedL() ) |
|
269 |
{ |
|
270 |
if ( NeedToSendToBackgroundL() ) |
|
56
5bcb308bd24d
Revision: 201031
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
37
diff
changeset
|
271 |
{ |
37 | 272 |
UpdateCbaL( EPhoneCallHandlingInCallCBA ); |
273 |
} |
|
274 |
else |
|
275 |
{ |
|
276 |
// Show the number entry if it exists. |
|
277 |
SetNumberEntryVisibilityL(ETrue); |
|
278 |
} |
|
279 |
} |
|
280 |
else |
|
281 |
{ |
|
282 |
UpdateCbaL( EPhoneCallHandlingNewCallSwapCBA ); |
|
283 |
// If numberentry is not open just check NeedToSendToBackgroundL and |
|
284 |
// sendbackround if needed. |
|
285 |
} |
|
286 |
SetTouchPaneButtons( EPhoneConferenceAndSingleButtons ); |
|
287 |
||
288 |
EndUiUpdate(); |
|
56
5bcb308bd24d
Revision: 201031
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
37
diff
changeset
|
289 |
|
37 | 290 |
// CBA updates in above if-else conditions |
291 |
iStateMachine->ChangeState( EPhoneStateConferenceAndSingle ); |
|
292 |
} |
|
293 |
||
294 |
// ----------------------------------------------------------- |
|
295 |
// CPhoneConferenceAndWaiting::HandleIdleL |
|
296 |
// ----------------------------------------------------------- |
|
297 |
// |
|
298 |
void CPhoneConferenceAndWaiting::HandleIdleL( TInt aCallId ) |
|
299 |
{ |
|
300 |
__LOGMETHODSTARTEND(EPhoneUIStates, "CPhoneConferenceAndWaiting::HandleIdleL()"); |
|
301 |
||
302 |
if ( iRingingCallId == KErrNotFound ) |
|
303 |
{ |
|
304 |
// Fetch ringing call's id from view |
|
305 |
TPhoneCmdParamCallStateData callStateData; |
|
306 |
callStateData.SetCallState( EPEStateRinging ); |
|
307 |
iViewCommandHandle->HandleCommandL( |
|
308 |
EPhoneViewGetCallIdByState, &callStateData ); |
|
309 |
iRingingCallId = callStateData.CallId(); |
|
310 |
} |
|
311 |
||
312 |
if( iRingingCallId == aCallId ) |
|
313 |
{ |
|
314 |
||
315 |
BeginUiUpdateLC(); |
|
316 |
||
317 |
// Remove call |
|
318 |
iViewCommandHandle->ExecuteCommandL( EPhoneViewRemoveCallHeader, aCallId ); |
|
319 |
||
320 |
if ( IsNumberEntryUsedL() ) |
|
321 |
{ |
|
322 |
if ( NeedToSendToBackgroundL() ) |
|
323 |
{ |
|
324 |
// Return phone to the background if send to background is needed. |
|
325 |
iViewCommandHandle->ExecuteCommandL( EPhoneViewSendToBackground ); |
|
56
5bcb308bd24d
Revision: 201031
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
37
diff
changeset
|
326 |
|
37 | 327 |
UpdateCbaL( EPhoneCallHandlingInCallCBA ); |
328 |
} |
|
329 |
else |
|
330 |
{ |
|
331 |
// Show the number entry if it exists. |
|
332 |
SetNumberEntryVisibilityL(ETrue); |
|
333 |
} |
|
334 |
} |
|
335 |
else |
|
336 |
{ |
|
337 |
UpdateCbaL( EPhoneCallHandlingInCallCBA ); |
|
338 |
// If numberentry is not open just check NeedToSendToBackgroundL and |
|
339 |
// sendbackround if needed. |
|
340 |
if ( NeedToSendToBackgroundL() ) |
|
341 |
{ |
|
342 |
// Return phone to the background if send to background is needed. |
|
343 |
iViewCommandHandle->ExecuteCommandL( EPhoneViewSendToBackground ); |
|
344 |
} |
|
345 |
} |
|
346 |
||
347 |
if( FeatureManager::FeatureSupported( KFeatureIdFfTouchUnlockStroke ) |
|
348 |
&& iStateMachine->PhoneStorage()->IsScreenLocked() ) |
|
349 |
{ |
|
350 |
EnableCallUIL(); |
|
351 |
} |
|
352 |
||
353 |
// Reset blocked keys list |
|
354 |
iStateMachine->PhoneStorage()->ResetBlockedKeysList(); |
|
355 |
||
56
5bcb308bd24d
Revision: 201031
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
37
diff
changeset
|
356 |
SetTouchPaneButtons( EPhoneConferenceButtons ); |
5bcb308bd24d
Revision: 201031
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
37
diff
changeset
|
357 |
|
37 | 358 |
EndUiUpdate(); |
359 |
||
360 |
// Go to conference state |
|
361 |
// CBA updates in above if-else conditions |
|
362 |
iStateMachine->ChangeState( EPhoneStateConference ); |
|
363 |
} |
|
364 |
else |
|
365 |
{ |
|
366 |
// Idle message came for conference member |
|
367 |
CPhoneConference::HandleIdleL( aCallId ); |
|
368 |
||
369 |
TPhoneCmdParamBoolean conferenceBubbleExists; |
|
370 |
iViewCommandHandle->ExecuteCommandL( EPhoneViewGetIsConference, |
|
371 |
&conferenceBubbleExists ); |
|
372 |
||
373 |
if( !conferenceBubbleExists.Boolean() ) |
|
374 |
{ |
|
375 |
HandleConferenceIdleL(); |
|
376 |
} |
|
377 |
} |
|
378 |
} |
|
379 |
||
380 |
// ----------------------------------------------------------- |
|
381 |
// CPhoneConferenceAndWaiting::HandleConferenceIdleL |
|
382 |
// ----------------------------------------------------------- |
|
383 |
// |
|
384 |
void CPhoneConferenceAndWaiting::HandleConferenceIdleL() |
|
385 |
{ |
|
386 |
__LOGMETHODSTARTEND( EPhoneUIStates, "CPhoneConferenceAndWaiting::HandleConferenceIdleL()"); |
|
387 |
||
388 |
BeginUiUpdateLC(); |
|
389 |
||
390 |
iViewCommandHandle->ExecuteCommandL( EPhoneViewRemoveConferenceBubble ); |
|
391 |
||
392 |
TPhoneCmdParamInteger activeCallCount; |
|
393 |
iViewCommandHandle->ExecuteCommandL( |
|
394 |
EPhoneViewGetCountOfActiveCalls, &activeCallCount ); |
|
395 |
||
396 |
switch( activeCallCount.Integer() ) |
|
397 |
{ |
|
398 |
case ENoActiveCalls: |
|
399 |
// Go to incoming state |
|
400 |
{ |
|
401 |
// Display ringing bubble |
|
402 |
TPhoneCmdParamCallHeaderData callHeaderParam; |
|
403 |
callHeaderParam.SetCallState( EPEStateRinging ); |
|
404 |
||
405 |
// Set Hold flag to view |
|
406 |
TPhoneCmdParamBoolean holdFlag; |
|
407 |
holdFlag.SetBoolean( EFalse ); |
|
408 |
iViewCommandHandle->ExecuteCommandL( EPhoneViewSetHoldFlag, &holdFlag ); |
|
409 |
||
410 |
// Bring up callhandling view |
|
411 |
BringIncomingToForegroundL(); |
|
412 |
||
413 |
SetCallHeaderTextsForCallComingInL( iRingingCallId, EFalse, &callHeaderParam ); |
|
414 |
||
415 |
iViewCommandHandle->ExecuteCommandL( EPhoneViewUpdateBubble, |
|
416 |
iRingingCallId ,&callHeaderParam ); |
|
417 |
iCbaManager->UpdateIncomingCbaL( iRingingCallId ); |
|
418 |
||
419 |
// Hide number entry if visible |
|
420 |
if ( IsNumberEntryVisibleL() ) |
|
421 |
{ |
|
422 |
SetNumberEntryVisibilityL(EFalse); |
|
423 |
} |
|
424 |
||
425 |
// Check if HW Keys or Call UI should be disabled |
|
426 |
CheckDisableHWKeysAndCallUIL(); |
|
427 |
||
428 |
SetTouchPaneButtons( EPhoneIncomingCallButtons ); |
|
429 |
SetRingingTonePlaybackL( iRingingCallId ); |
|
430 |
SetBackButtonActive(EFalse); |
|
431 |
iStateMachine->ChangeState( EPhoneStateIncoming ); |
|
432 |
break; |
|
433 |
} |
|
434 |
||
435 |
case EOneActiveCall: |
|
436 |
if ( IsNumberEntryUsedL() ) |
|
437 |
{ |
|
438 |
// Show the number entry if it exists |
|
439 |
SetNumberEntryVisibilityL(ETrue); |
|
440 |
} |
|
441 |
// Go to waiting in single state |
|
442 |
UpdateCbaL( EPhoneCallHandlingCallWaitingCBA ); |
|
443 |
||
444 |
// Check if HW Keys or Call UI should be disabled |
|
445 |
CheckDisableHWKeysAndCallUIL(); |
|
446 |
||
447 |
SetTouchPaneButtons( EPhoneWaitingCallButtons ); |
|
448 |
iStateMachine->ChangeState( EPhoneStateWaitingInSingle ); |
|
449 |
break; |
|
450 |
||
451 |
case ETwoActiveCalls: |
|
452 |
if ( IsNumberEntryUsedL() ) |
|
453 |
{ |
|
454 |
// Show the number entry if it exists |
|
455 |
SetNumberEntryVisibilityL(ETrue); |
|
456 |
} |
|
457 |
// Go to two singles and waiting state |
|
458 |
UpdateCbaL( EPhoneCallHandlingCallWaitingCBA ); |
|
459 |
||
460 |
// Check if HW Keys or Call UI should be disabled |
|
461 |
CheckDisableHWKeysAndCallUIL(); |
|
462 |
||
463 |
SetTouchPaneButtons( EPhoneWaitingCallButtons ); |
|
464 |
||
465 |
iStateMachine->ChangeState( EPhoneStateTwoSinglesAndWaiting ); |
|
466 |
break; |
|
467 |
default: |
|
468 |
// Too many active calls to handle reliable state change now. |
|
469 |
// Waiting for all conference member idles |
|
470 |
// This case may happen when 'End all calls' because conferenceIdle may |
|
471 |
// come earlier than idle for conference member |
|
472 |
break; |
|
473 |
} |
|
474 |
EndUiUpdate(); |
|
475 |
} |
|
476 |
||
477 |
// ----------------------------------------------------------- |
|
478 |
// CPhoneConferenceAndWaiting::UpdateInCallCbaL |
|
479 |
// ----------------------------------------------------------- |
|
480 |
// |
|
481 |
void CPhoneConferenceAndWaiting::UpdateInCallCbaL() |
|
482 |
{ |
|
483 |
__LOGMETHODSTARTEND( EPhoneUIStates, "CPhoneConferenceAndWaiting::UpdateInCallCbaL() "); |
|
484 |
UpdateCbaL ( EPhoneCallHandlingCallWaitingCBA ); |
|
485 |
} |
|
486 |
||
487 |
// ----------------------------------------------------------- |
|
488 |
// CPhoneConferenceAndWaiting::HandleDiallingL |
|
489 |
// ----------------------------------------------------------- |
|
490 |
// |
|
491 |
void CPhoneConferenceAndWaiting::HandleDiallingL( TInt aCallId ) |
|
492 |
{ |
|
493 |
__LOGMETHODSTARTEND( EPhoneUIStates, |
|
494 |
"CPhoneConferenceAndWaiting::HandleDiallingL()"); |
|
56
5bcb308bd24d
Revision: 201031
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
37
diff
changeset
|
495 |
|
37 | 496 |
BeginUiUpdateLC(); |
497 |
// Hide number entry if it exists |
|
498 |
SetNumberEntryVisibilityL(EFalse); |
|
499 |
||
500 |
// Display call setup |
|
501 |
DisplayCallSetupL( aCallId ); |
|
502 |
||
503 |
SetTouchPaneButtons( EPhoneCallSetupButtons ); |
|
504 |
||
505 |
EndUiUpdate(); |
|
506 |
||
507 |
// Update conference and waiting and call setup softkeys |
|
508 |
UpdateCbaL( EPhoneCallHandlingCallSetupCBA ); |
|
509 |
||
510 |
// Go to conference and waiting and call setup state |
|
511 |
iStateMachine->ChangeState( EPhoneStateConferenceAndWaitingAndCallSetup ); |
|
512 |
} |
|
513 |
||
514 |
// ----------------------------------------------------------- |
|
515 |
// CPhoneConferenceAndWaiting::HandleWentOneToOneL |
|
516 |
// ----------------------------------------------------------- |
|
517 |
// |
|
518 |
void CPhoneConferenceAndWaiting::HandleWentOneToOneL( TInt aCallId ) |
|
519 |
{ |
|
520 |
__LOGMETHODSTARTEND( EPhoneUIStates, |
|
521 |
"CPhoneConferenceAndWaiting::HandleWentOneToOneL()"); |
|
522 |
||
523 |
BeginUiUpdateLC(); |
|
524 |
||
525 |
// Update conference bubble |
|
526 |
iViewCommandHandle->ExecuteCommandL( |
|
527 |
EPhoneViewPrivateFromConference, aCallId ); |
|
528 |
||
529 |
if ( iRingingCallId == KErrNotFound ) |
|
530 |
{ |
|
531 |
// Fetch ringing call's id from view |
|
532 |
TPhoneCmdParamCallStateData callStateData; |
|
533 |
callStateData.SetCallState( EPEStateRinging ); |
|
534 |
iViewCommandHandle->HandleCommandL( |
|
535 |
EPhoneViewGetCallIdByState, &callStateData ); |
|
536 |
iRingingCallId = callStateData.CallId(); |
|
537 |
} |
|
538 |
||
539 |
TPhoneCmdParamBoolean conferenceBubbleExists; |
|
540 |
iViewCommandHandle->ExecuteCommandL( EPhoneViewGetIsConference, |
|
541 |
&conferenceBubbleExists ); |
|
542 |
if( conferenceBubbleExists.Boolean() && |
|
543 |
( iRingingCallId != KErrNotFound ) ) |
|
544 |
{ |
|
545 |
SetTouchPaneButtons( EPhoneWaitingCallButtons ); |
|
546 |
UpdateCbaL( EPhoneCallHandlingCallWaitingCBA ); |
|
547 |
// Go to Conference And Single And Waiting state |
|
548 |
iStateMachine->ChangeState( EPhoneStateConferenceAndSingleAndWaiting ); |
|
549 |
} |
|
550 |
||
551 |
EndUiUpdate(); |
|
552 |
} |
|
553 |
||
554 |
// ----------------------------------------------------------- |
|
555 |
// CPhoneConferenceAndWaiting::HandleCommandL |
|
556 |
// ----------------------------------------------------------- |
|
557 |
// |
|
558 |
TBool CPhoneConferenceAndWaiting::HandleCommandL( TInt aCommand ) |
|
559 |
{ |
|
560 |
__LOGMETHODSTARTEND( EPhoneUIStates, |
|
561 |
"CPhoneConferenceAndWaiting::HandleCommandL() "); |
|
562 |
TBool commandStatus = ETrue; |
|
563 |
||
564 |
switch( aCommand ) |
|
565 |
{ |
|
566 |
case EPhoneCmdUpdateUiControls: |
|
567 |
UpdateUiControlsL(); |
|
568 |
break; |
|
569 |
||
570 |
default: |
|
571 |
commandStatus = CPhoneConference::HandleCommandL( aCommand ); |
|
572 |
break; |
|
573 |
} |
|
574 |
||
575 |
return commandStatus; |
|
576 |
} |
|
577 |
||
578 |
// ----------------------------------------------------------- |
|
579 |
// CPhoneConferenceAndWaiting::UpdateUiControlsL |
|
580 |
// ----------------------------------------------------------- |
|
581 |
// |
|
582 |
void CPhoneConferenceAndWaiting::UpdateUiControlsL() |
|
583 |
{ |
|
584 |
__LOGMETHODSTARTEND( EPhoneUIStates, "CPhoneConferenceAndWaiting::UpdateUiControlsL( ) "); |
|
585 |
iViewCommandHandle->ExecuteCommand(EPhoneSetConferenceExpanded); |
|
586 |
UpdateCbaL( EPhoneCallHandlingInCallCBA ); |
|
587 |
} |
|
588 |
||
589 |
// End of File |