diff -r 3c221667e687 -r 94dc1107e8b2 phoneapp/phoneuistates/src/cphoneemergency.cpp --- a/phoneapp/phoneuistates/src/cphoneemergency.cpp Mon Jun 21 15:39:45 2010 +0300 +++ b/phoneapp/phoneuistates/src/cphoneemergency.cpp Thu Jul 15 18:38:16 2010 +0300 @@ -45,8 +45,10 @@ // ================= MEMBER FUNCTIONS ======================= +// ----------------------------------------------------------- // C++ default constructor can NOT contain any code, that // might leave. +// ----------------------------------------------------------- // CPhoneEmergency::CPhoneEmergency( MPhoneStateMachine* aStateMachine, @@ -62,7 +64,7 @@ // Destructor // (other items were commented in a header). // ----------------------------------------------------------- - +// CPhoneEmergency::~CPhoneEmergency() { } @@ -183,10 +185,10 @@ } } break; - + case MEngineMonitor::EPEMessageColpNumberAvailable: //Don't show COLP note during emergency call. - break; + break; default: CPhoneGsmInCall::HandlePhoneEngineMessageL( @@ -551,11 +553,11 @@ } } else if ( iStateMachine->SecurityMode()->IsAutolockEnabled() - || SimState() != EPESimUsable - || iStartupInterrupted ) + || SimState() != EPESimUsable + || iStartupInterrupted ) { if ( TouchCallHandlingSupported() ) - { + { resourceId = EPhoneCallHandlingEmergencyInCallNoOptions; } else if ( audioOutput == EPEWiredAudioAccessory || IsSwivelClosed()) @@ -581,8 +583,8 @@ { resourceId = EPhoneCallHandlingEmergencyHandsetCBA; } - else if ( ( audioOutput == EPEHandset ) - && ( btAvailable ) ) + else if ( ( audioOutput == EPEHandset ) + && ( btAvailable ) ) { resourceId = EPhoneCallHandlingInCallBtaaCBA; } @@ -643,10 +645,10 @@ { if ( TouchCallHandlingSupported() ) { - CPhoneGsmInCall::HandleKeyMessageL( aMessage, aCode ); + CPhoneGsmInCall::HandleKeyMessageL( aMessage, aCode ); } else if ( !iStateMachine->SecurityMode()->IsAutolockEnabled() - && SimState() == EPESimUsable ) + && SimState() == EPESimUsable ) { // do base operation CPhoneGsmInCall::HandleKeyMessageL( aMessage, aCode ); @@ -696,6 +698,10 @@ DisconnectEmergencyCallL(); break; + case EPhoneCmdUpdateEmergencyCba: + UpdateInCallCbaL(); + break; + default: commandStatus = CPhoneGsmInCall::HandleCommandL( aCommand ); break; @@ -768,24 +774,24 @@ TEventCode aEventCode ) { __LOGMETHODSTARTEND(EPhoneUIStates, "CPhoneEmergency::HandleKeyEventL( ) "); - + if ( TouchCallHandlingSupported() ) { CPhoneState::HandleKeyEventL( aKeyEvent, aEventCode ); } else { - if ( iStateMachine->SecurityMode()->IsAutolockEnabled() - && CPhoneKeys::IsNumericKey( aKeyEvent, aEventCode ) ) - { - // Send the key event to the phone engine - SendKeyEventL( aKeyEvent, aEventCode ); - } - else - { - // Handle numeric keys when key events are received in idle state - CPhoneState::HandleKeyEventL( aKeyEvent, aEventCode ); - } + if ( iStateMachine->SecurityMode()->IsAutolockEnabled() + && CPhoneKeys::IsNumericKey( aKeyEvent, aEventCode ) ) + { + // Send the key event to the phone engine + SendKeyEventL( aKeyEvent, aEventCode ); + } + else + { + // Handle numeric keys when key events are received in idle state + CPhoneState::HandleKeyEventL( aKeyEvent, aEventCode ); + } } } @@ -880,8 +886,8 @@ const TPEAudioOutput audioOutput = iStateMachine->PhoneEngineInfo()->AudioOutput(); - if ( !( TouchCallHandlingSupported() ) - && iCallSetup && audioOutput != EPENotActive ) + if ( !( TouchCallHandlingSupported() ) + && iCallSetup && audioOutput != EPENotActive ) { if ( audioOutput == EPELoudspeaker ) { @@ -951,33 +957,33 @@ // -------------------------------------------------------------- // TBool CPhoneEmergency::TouchCallHandlingSupported () const - { - if ( FeatureManager::FeatureSupported ( KFeatureIdTouchCallHandling ) ) - { - return ETrue; - } - else - { - return EFalse; - } - } + { + if ( FeatureManager::FeatureSupported ( KFeatureIdTouchCallHandling ) ) + { + return ETrue; + } + else + { + return EFalse; + } + } // -------------------------------------------------------------- // CPhoneEmergency::UseEmergencyNoIhfCBA // -------------------------------------------------------------- // TBool CPhoneEmergency::UseEmergencyNoIhfCBA( const TPEAudioOutput& aAudioOutput ) const - { - if ( !( TouchCallHandlingSupported() ) - && ( ( aAudioOutput == EPEWiredAudioAccessory ) || ( IsSwivelClosed() ) ) ) - { - return ETrue; - } - else - { - return EFalse; - } - } + { + if ( !( TouchCallHandlingSupported() ) + && ( ( aAudioOutput == EPEWiredAudioAccessory ) || ( IsSwivelClosed() ) ) ) + { + return ETrue; + } + else + { + return EFalse; + } + } // -------------------------------------------------------------- // CPhoneEmergency::UseHandsetEmergencyCBA @@ -985,15 +991,15 @@ // TBool CPhoneEmergency::UseHandsetEmergencyCBA( const TPEAudioOutput& aAudioOutput ) const { - if ( !( TouchCallHandlingSupported() ) - && ( ( aAudioOutput == EPELoudspeaker ) || ( aAudioOutput == EPEBTAudioAccessory ) ) ) - { - return ETrue; - } - else - { - return EFalse; - } + if ( !( TouchCallHandlingSupported() ) + && ( ( aAudioOutput == EPELoudspeaker ) || ( aAudioOutput == EPEBTAudioAccessory ) ) ) + { + return ETrue; + } + else + { + return EFalse; + } } // --------------------------------------------------------------