phoneapp/phoneuicontrol/src/cphonestateincall.cpp
branchRCL_3
changeset 26 8baf28733c3d
parent 25 5266b1f337bd
equal deleted inserted replaced
25:5266b1f337bd 26:8baf28733c3d
   139             HandleVoiceKeyPressL( aMessage ); 
   139             HandleVoiceKeyPressL( aMessage ); 
   140             break;
   140             break;
   141             
   141             
   142 #ifdef RD_INTELLIGENT_TEXT_INPUT
   142 #ifdef RD_INTELLIGENT_TEXT_INPUT
   143         case EKeyEnter:
   143         case EKeyEnter:
   144             if ( iOnScreenDialer && IsDTMFEditorVisibleL() )
   144             {
       
   145             TPhoneCmdParamInteger numberEntryCountParam;
       
   146             iViewCommandHandle->ExecuteCommandL( 
       
   147                  EPhoneViewGetNumberEntryCount,
       
   148                  &numberEntryCountParam );
       
   149             
       
   150             TInt neLength( numberEntryCountParam.Integer() );
       
   151                       
       
   152             if ( iOnScreenDialer && IsDTMFEditorVisibleL() && neLength > 0 )
   145                 {
   153                 {
   146                 SendDtmfL();    
   154                 SendDtmfL();    
   147                 }
   155                 }
   148             else if ( IsNumberEntryVisibleL() )
   156             else if ( IsNumberEntryVisibleL() )
   149                 {
   157                 {
   152                     iViewCommandHandle->HandleCommandL(
   160                     iViewCommandHandle->HandleCommandL(
   153                                        EEasyDialingEnterKeyAction );
   161                                        EEasyDialingEnterKeyAction );
   154                     }
   162                     }
   155                 else
   163                 else
   156                     {
   164                     {
   157                     TPhoneCmdParamInteger numberEntryCountParam;
       
   158                     iViewCommandHandle->ExecuteCommandL( 
       
   159                            EPhoneViewGetNumberEntryCount,
       
   160                            &numberEntryCountParam );
       
   161                     
       
   162                     TInt neLength( numberEntryCountParam.Integer() );
       
   163                     if ( neLength > 0 )
   165                     if ( neLength > 0 )
   164                        {
   166                        {
   165                        HandleCommandL( EPhoneNumberAcqCmdSendCommand );
   167                        HandleCommandL( EPhoneNumberAcqCmdSendCommand );
   166                        }
   168                        }
   167                     }      
   169                     }      
   168                 }
   170                 }
       
   171             }
   169             break;
   172             break;
   170 #endif            
   173 #endif            
   171           
   174           
   172         default:
   175         default:
   173             break;
   176             break;
   304 EXPORT_C void CPhoneStateInCall::HandleIdleL( TInt aCallId )
   307 EXPORT_C void CPhoneStateInCall::HandleIdleL( TInt aCallId )
   305     {
   308     {
   306     __LOGMETHODSTARTEND(EPhoneControl,  
   309     __LOGMETHODSTARTEND(EPhoneControl,  
   307         "CPhoneStateInCall::HandleIdleL()" );
   310         "CPhoneStateInCall::HandleIdleL()" );
   308     __ASSERT_DEBUG( aCallId >= 0, Panic( EPhoneCtrlParameterNotInitialized ) );
   311     __ASSERT_DEBUG( aCallId >= 0, Panic( EPhoneCtrlParameterNotInitialized ) );
       
   312     TransitionHandlerL().IdleCallUiUpdateLC();
       
   313     
   309     iViewCommandHandle->ExecuteCommandL( EPhoneViewRemoveCallHeader, aCallId );
   314     iViewCommandHandle->ExecuteCommandL( EPhoneViewRemoveCallHeader, aCallId );
   310     iViewCommandHandle->ExecuteCommandL( EPhoneViewHideToolbar );
   315     iViewCommandHandle->ExecuteCommandL( EPhoneViewHideToolbar );
   311     if (  IsNumberEntryUsedL() )
       
   312         {
       
   313         BeginTransEffectLC( ECallUiDisappear );
       
   314         }
       
   315     else 
       
   316         {
       
   317         BeginTransEffectLC( ENumberEntryClose );
       
   318         }
       
   319     BeginUiUpdateLC();
       
   320     SetDefaultFlagsL();
   316     SetDefaultFlagsL();
   321         
   317         
   322     if ( IsNumberEntryUsedL() )
   318     if ( IsNumberEntryUsedL() )
   323         {
   319         {
   324         // Show the number entry if it exists and update cba's.
   320         // Show the number entry if it exists and update cba's.
   352             DisplayIdleScreenL();
   348             DisplayIdleScreenL();
   353             }
   349             }
   354         }
   350         }
   355         
   351         
   356     DeleteTouchPaneButtons();
   352     DeleteTouchPaneButtons();
   357     EndUiUpdate();
   353     TransitionHandlerL().EndUiUpdateAndEffect();
   358     EndTransEffect();
       
   359     DisplayCallTerminationNoteL();
   354     DisplayCallTerminationNoteL();
   360     iStateMachine->ChangeState( EPhoneStateIdle );
   355     iStateMachine->ChangeState( EPhoneStateIdle );
   361     iViewCommandHandle->ExecuteCommandL( EPhoneViewHideToolbar );
   356     iViewCommandHandle->ExecuteCommandL( EPhoneViewHideToolbar );
   362     }
   357     }
   363 
   358 
   609     TBool commandStatus = ETrue;
   604     TBool commandStatus = ETrue;
   610 
   605 
   611     switch( aCommand )
   606     switch( aCommand )
   612         {
   607         {
   613         case EPhoneInCallCmdDialer:
   608         case EPhoneInCallCmdDialer:
   614             BeginTransEffectLC( ECallUiDisappear );
   609             TransitionHandlerL().
       
   610                 BeginTransEffectLC( EPhoneTransEffectCallUiDisappear );
   615             if ( !IsNumberEntryUsedL() )
   611             if ( !IsNumberEntryUsedL() )
   616                 {
   612                 {
   617                 CreateNumberEntryL();
   613                 CreateNumberEntryL();
   618                 }
   614                 }
   619             SetNumberEntryVisibilityL( ETrue ); 
   615             SetNumberEntryVisibilityL( ETrue ); 
   620             EndTransEffect();
   616             TransitionHandlerL().EndTransEffect();
   621           break;
   617           break;
   622           
   618           
   623         case EPhoneCmdOptions:
   619         case EPhoneCmdOptions:
   624             OpenMenuBarL();
   620             OpenMenuBarL();
   625             break;
   621             break;
   849             break;
   845             break;
   850 
   846 
   851        case EPhoneViewOpenCallHandling:
   847        case EPhoneViewOpenCallHandling:
   852             if ( iOnScreenDialer && IsNumberEntryUsedL() )
   848             if ( iOnScreenDialer && IsNumberEntryUsedL() )
   853                 {
   849                 {
   854                 BeginTransEffectLC( ECallUiAppear );
   850                 TransitionHandlerL().
       
   851                         BeginTransEffectLC( EPhoneTransEffectCallUiAppear );
   855                 // Remove number entry from screen
   852                 // Remove number entry from screen
   856                 iViewCommandHandle->ExecuteCommandL( EPhoneViewRemoveNumberEntry );
   853                 iViewCommandHandle->ExecuteCommandL( EPhoneViewRemoveNumberEntry );
   857                 EndTransEffect();
   854                 TransitionHandlerL().EndTransEffect();
   858                 HandleNumberEntryClearedL();
   855                 HandleNumberEntryClearedL();
   859                 }
   856                 }
   860             commandStatus = CPhoneState::HandleCommandL( aCommand );        
   857             commandStatus = CPhoneState::HandleCommandL( aCommand );        
   861             break;
   858             break;
   862  
   859  
   927         "CPhoneStateInCall::LaunchNewCallQueryL()" );
   924         "CPhoneStateInCall::LaunchNewCallQueryL()" );
   928     
   925     
   929     if ( iOnScreenDialer )
   926     if ( iOnScreenDialer )
   930         {
   927         {
   931         //In touch, just activate dialer
   928         //In touch, just activate dialer
   932         BeginTransEffectLC( ECallUiDisappear );
   929         TransitionHandlerL().
       
   930                 BeginTransEffectLC( EPhoneTransEffectCallUiDisappear );
   933         if ( IsNumberEntryUsedL() )
   931         if ( IsNumberEntryUsedL() )
   934             {
   932             {
   935             SetNumberEntryVisibilityL(ETrue);   
   933             SetNumberEntryVisibilityL(ETrue);   
   936             }
   934             }
   937         else
   935         else
   938             {
   936             {
   939             CreateNumberEntryL();
   937             CreateNumberEntryL();
   940             SetNumberEntryVisibilityL(ETrue); 
   938             SetNumberEntryVisibilityL(ETrue); 
   941             }
   939             }
   942         EndTransEffect();
   940         TransitionHandlerL().EndTransEffect();
   943         }
   941         }
   944     else
   942     else
   945         {
   943         {
   946         HBufC *text = HBufC::NewLC( KPhoneNumberEntryBufferSize );
   944         HBufC *text = HBufC::NewLC( KPhoneNumberEntryBufferSize );
   947         TPtr ptr( text->Des() );
   945         TPtr ptr( text->Des() );
  1556                 {
  1554                 {
  1557                 CloseDTMFEditorL();
  1555                 CloseDTMFEditorL();
  1558                 }
  1556                 }
  1559             else
  1557             else
  1560                 {    
  1558                 {    
  1561                 CloseClearNumberEntryAndLoadEffectL( ENumberEntryClose );
  1559                 CloseClearNumberEntryAndLoadEffectL( EPhoneTransEffectPhoneUiClose );
  1562                 }
  1560                 }
  1563             }
  1561             }
  1564 
  1562 
  1565         if ( !TopAppIsDisplayedL() )
  1563         if ( !TopAppIsDisplayedL() )
  1566             {
  1564             {
  1650         const TUid& aCategory, const TUint aKey, const TInt aValue)
  1648         const TUid& aCategory, const TUint aKey, const TInt aValue)
  1651     {
  1649     {
  1652     if ( aCategory == KPSUidCoreApplicationUIs &&
  1650     if ( aCategory == KPSUidCoreApplicationUIs &&
  1653          aKey == KCoreAppUIsVideoSharingIndicator )
  1651          aKey == KCoreAppUIsVideoSharingIndicator )
  1654         {
  1652         {
  1655         if ( aValue == ECoreAppUIsVideoSharingIndicatorOn )
  1653         SetTouchPaneButtons( EPhoneIncallButtons );
  1656             {
       
  1657             SetTouchPaneButtons( EPhoneIncallVideoShareButtons );
       
  1658             }
       
  1659         else
       
  1660             {
       
  1661             SetTouchPaneButtons( EPhoneIncallButtons );
       
  1662             }
       
  1663         }
  1654         }
  1664     else
  1655     else
  1665         {
  1656         {
  1666         CPhoneState::HandlePropertyChangedL( aCategory, aKey, aValue );
  1657         CPhoneState::HandlePropertyChangedL( aCategory, aKey, aValue );
  1667         }
  1658         }