198 EPhoneViewGetCountOfActiveCalls, &activeCallCount ); |
198 EPhoneViewGetCountOfActiveCalls, &activeCallCount ); |
199 |
199 |
200 switch( activeCallCount.Integer() ) |
200 switch( activeCallCount.Integer() ) |
201 { |
201 { |
202 case EOneActiveCall: |
202 case EOneActiveCall: |
203 { |
203 { |
204 if ( IsNumberEntryUsedL() ) |
204 // Close menu bar if number entry is not open. |
205 { |
205 iViewCommandHandle->ExecuteCommandL( EPhoneViewMenuBarClose ); |
206 // Show the number entry if it exists |
|
207 SetNumberEntryVisibilityL(ETrue); |
|
208 } |
|
209 else |
|
210 { |
|
211 // Close menu bar if number entry is not open. |
|
212 iViewCommandHandle->ExecuteCommandL( EPhoneViewMenuBarClose ); |
|
213 |
206 |
214 // Set incall CBAs |
207 // Set incall CBAs |
215 UpdateCbaL( EPhoneCallHandlingInCallCBA ); |
208 UpdateCbaL( EPhoneCallHandlingInCallCBA ); |
216 } |
|
217 |
209 |
218 TPhoneCmdParamCallStateData callStateData; |
210 TPhoneCmdParamCallStateData callStateData; |
219 callStateData.SetCallState( EPEStateHeld ); |
211 callStateData.SetCallState( EPEStateHeld ); |
220 iViewCommandHandle->HandleCommandL( |
212 iViewCommandHandle->HandleCommandL( |
221 EPhoneViewGetCallIdByState, &callStateData ); |
213 EPhoneViewGetCallIdByState, &callStateData ); |
443 __LOGMETHODSTARTEND( EPhoneUIStates, |
435 __LOGMETHODSTARTEND( EPhoneUIStates, |
444 "CPhoneTwoSingles::DisplayIncomingCallL()"); |
436 "CPhoneTwoSingles::DisplayIncomingCallL()"); |
445 // Close menu bar, if it is displayed |
437 // Close menu bar, if it is displayed |
446 iViewCommandHandle->ExecuteCommandL( EPhoneViewMenuBarClose ); |
438 iViewCommandHandle->ExecuteCommandL( EPhoneViewMenuBarClose ); |
447 |
439 |
448 // Cannot delete active note, e.g. New call query, |
440 // Remove any phone dialogs if they are displayed |
449 // but show waiting note with or without caller name |
441 iViewCommandHandle->ExecuteCommandL( EPhoneViewRemovePhoneDialogs ); |
450 if ( IsAnyQueryActiveL() || |
|
451 ( !aCommandParam.Boolean() && iOnScreenDialer ) ) |
|
452 { |
|
453 CallWaitingNoteL( aCallId ); |
|
454 } |
|
455 else |
|
456 { |
|
457 // Remove any phone dialogs if they are displayed |
|
458 iViewCommandHandle->ExecuteCommandL( EPhoneViewRemovePhoneDialogs ); |
|
459 } |
|
460 |
442 |
461 // Indicate that the Phone needs to be sent to the background if |
443 // Indicate that the Phone needs to be sent to the background if |
462 // an application other than the top application is in the foreground |
444 // an application other than the top application is in the foreground |
463 TPhoneCmdParamBoolean booleanParam; |
445 TPhoneCmdParamBoolean booleanParam; |
464 booleanParam.SetBoolean( !TopAppIsDisplayedL() ); |
446 booleanParam.SetBoolean( !TopAppIsDisplayedL() ); |
465 iViewCommandHandle->ExecuteCommandL( |
447 iViewCommandHandle->ExecuteCommandL( |
466 EPhoneViewSetNeedToSendToBackgroundStatus, |
448 EPhoneViewSetNeedToReturnToForegroundAppStatus, |
467 &booleanParam ); |
449 &booleanParam ); |
468 |
450 |
469 // Bring Phone app in the foreground |
451 // Bring Phone app in the foreground |
470 TPhoneCmdParamInteger uidParam; |
452 TPhoneCmdParamInteger uidParam; |
471 uidParam.SetInteger( KUidPhoneApplication.iUid ); |
453 uidParam.SetInteger( KUidPhoneApplication.iUid ); |