phoneapp/phoneuicontrol/src/cphonestatecallsetup.cpp
branchRCL_3
changeset 58 40a3f856b14d
parent 25 91c2fb4b78df
child 61 41a7f70b3818
--- a/phoneapp/phoneuicontrol/src/cphonestatecallsetup.cpp	Thu Jul 15 18:38:16 2010 +0300
+++ b/phoneapp/phoneuicontrol/src/cphonestatecallsetup.cpp	Thu Aug 19 09:54:27 2010 +0300
@@ -87,11 +87,17 @@
     // Enable the volume display
     iViewCommandHandle->ExecuteCommandL( EPhoneViewShowNaviPaneAudioVolume );   
     HandleAudioOutputChangedL();
-     
-    CPhonePubSubProxy::Instance()->ChangePropertyValue(
-                    KPSUidScreenSaver,
-                    KScreenSaverAllowScreenSaver,
-                    EPhoneScreensaverNotAllowed );
+
+    TPhoneCmdParamCallStateData callStateData;
+    callStateData.SetCallState( EPEStateDialing );
+    iViewCommandHandle->HandleCommandL( EPhoneViewGetCallIdByState, &callStateData );
+    if ( callStateData.CallId() > KErrNotFound && IsVideoCall( callStateData.CallId() ) )
+        {
+        CPhonePubSubProxy::Instance()->ChangePropertyValue(
+                        KPSUidScreenSaver,
+                        KScreenSaverAllowScreenSaver,
+                        EPhoneScreensaverNotAllowed );
+        }
     }
 
 // -----------------------------------------------------------
@@ -245,10 +251,8 @@
     {
     __LOGMETHODSTARTEND(EPhoneControl,  
         "CPhoneStateCallSetup::HandleCreateNumberEntryL()" );
-    
     }
 
-
 // -----------------------------------------------------------
 // CPhoneStateCallSetup::UpdateInCallCbaL
 // -----------------------------------------------------------
@@ -608,8 +612,16 @@
 void CPhoneStateCallSetup::HandleIdleL( TInt aCallId )
     {
     __LOGMETHODSTARTEND(EPhoneControl, "CPhoneStateCallSetup::HandleIdleL()");
-    
-    BeginUiUpdateLC ();
+    if ( !NeedToReturnToForegroundAppL() &&
+         IsNumberEntryUsedL() )
+        {
+        BeginTransEffectLC( ECallUiDisappear );
+        }
+    else 
+        {
+        BeginTransEffectLC( ENumberEntryOpen );
+        }
+    BeginUiUpdateLC();
     
     // Disable the volume display
     iViewCommandHandle->ExecuteCommandL( EPhoneViewHideNaviPaneAudioVolume );
@@ -622,8 +634,21 @@
       
     if ( IsNumberEntryUsedL() )
         {
-        // Show the number entry if it exists
-        SetNumberEntryVisibilityL(ETrue);    
+        if ( NeedToReturnToForegroundAppL() )
+            {
+            // Return phone to the background if send to background is needed.
+            iViewCommandHandle->ExecuteCommandL( EPhoneViewSendToBackground );
+    
+            iViewCommandHandle->ExecuteCommandL( EPhoneViewSetControlAndVisibility );
+    
+            // Set Number Entry CBA
+            iCbaManager->SetCbaL( EPhoneNumberAcqCBA );
+            }
+        else
+            {
+            // Show the number entry if it exists
+            SetNumberEntryVisibilityL(ETrue);
+            }
         }    
     else if ( NeedToReturnToForegroundAppL() )
         {
@@ -640,8 +665,7 @@
         }
         
     EndUiUpdate();
-
-    // Go to idle state
+    EndTransEffect(); 
     // No need update cba
     iStateMachine->ChangeState( EPhoneStateIdle );
     }