camerauis/cameraapp/generic/src/CamCaptureSetupContainer.cpp
branchRCL_3
changeset 12 51dda465e618
parent 10 8c55c525d5d7
child 13 38fb6f7eacd5
equal deleted inserted replaced
11:d486e5e3cc9a 12:51dda465e618
   372     {
   372     {
   373     if( iController.CurrentMode() == ECamControllerIdle || 
   373     if( iController.CurrentMode() == ECamControllerIdle || 
   374         iController.CurrentMode() == ECamControllerShutdown )
   374         iController.CurrentMode() == ECamControllerShutdown )
   375         {
   375         {
   376         if( !iController.IsViewFinding() && iViewFinding 
   376         if( !iController.IsViewFinding() && iViewFinding 
   377            && IsCaptureKeyL( aKeyEvent, aType ) )             
   377             && ( IsCaptureKeyL( aKeyEvent, aType )
       
   378             || IsShutterKeyL( aKeyEvent, aType ) ) )
   378             {
   379             {
   379             PRINT( _L("Camera <> CCamCaptureSetupContainer::OfferKeyEventL coming back from standby" ))
   380             PRINT( _L("Camera <> CCamCaptureSetupContainer::OfferKeyEventL coming back from standby" ))
   380             ReserveAndStartVF();
   381             ReserveAndStartVF();
   381             }
   382             }
   382         return EKeyWasNotConsumed;
   383         return EKeyWasNotConsumed;
   389        && IsCaptureKeyL( aKeyEvent, aType ) )             
   390        && IsCaptureKeyL( aKeyEvent, aType ) )             
   390         {
   391         {
   391         // If VF was stopped by stand-by-timer, restart VF here
   392         // If VF was stopped by stand-by-timer, restart VF here
   392         ReserveAndStartVF();
   393         ReserveAndStartVF();
   393         }
   394         }
   394 
   395     
   395     // If the Ok button is pressed, select the current item
   396     // If the Ok button or shutter key is pressed, select the current item
   396     if ( aKeyEvent.iCode == EKeyOK && aKeyEvent.iRepeats == 0 && aType == EEventKey )
   397     if ( ( aKeyEvent.iCode == EKeyOK && aKeyEvent.iRepeats == 0 && aType == EEventKey ) ||
       
   398          ( aType == EEventKeyDown && 
       
   399          ( IsCaptureKeyL( aKeyEvent, aType ) || IsShutterKeyL( aKeyEvent, aType ) ) ) )  
   397         {
   400         {
   398         TKeyResponse response = iCaptureSetupControl->OfferKeyEventL( aKeyEvent, aType );
   401         TKeyResponse response = iCaptureSetupControl->OfferKeyEventL( aKeyEvent, aType );
   399         iView.HandleCommandL( EAknSoftkeyOk );
   402         iView.HandleCommandL( EAknSoftkeyOk );
   400         return response;
   403         return response;
   401         }
   404         }