multimediacommsengine/tsrc/MCETestUI/MCETestUIEngine/src/TMCETestUIEngineCmdRingingSession.cpp
changeset 0 1bce908db942
equal deleted inserted replaced
-1:000000000000 0:1bce908db942
       
     1 /*
       
     2 * Copyright (c) 2005 Nokia Corporation and/or its subsidiary(-ies).
       
     3 * All rights reserved.
       
     4 * This component and the accompanying materials are made available
       
     5 * under the terms of "Eclipse Public License v1.0"
       
     6 * which accompanies this distribution, and is available
       
     7 * at the URL "http://www.eclipse.org/legal/epl-v10.html".
       
     8 *
       
     9 * Initial Contributors:
       
    10 * Nokia Corporation - initial contribution.
       
    11 *
       
    12 * Contributors:
       
    13 *
       
    14 * Description:    Implementation.
       
    15 *
       
    16 */
       
    17 
       
    18 
       
    19 
       
    20 
       
    21 // INCLUDES
       
    22 
       
    23 #include "TMCETestUIEngineCmdRingingSession.h"
       
    24 #include "CMCETestUIEngineInSession.h"
       
    25 //#include "CMCETestUIQuestionSingleSelection.h"
       
    26 #include <MCEInSession.h>
       
    27 
       
    28 // -----------------------------------------------------------------------------
       
    29 // TMCETestUIEngineCmdRejectSession::TMCETestUIEngineCmdRejectSession
       
    30 // -----------------------------------------------------------------------------
       
    31 //
       
    32 TMCETestUIEngineCmdRingingSession::TMCETestUIEngineCmdRingingSession( 
       
    33 		            CMCETestUIEngine& aEngine,
       
    34 		            CMCETestUIEngineInSession& aInSession )
       
    35     : TMCETestUIEngineCmdBase( aEngine ),
       
    36       iInSession( aInSession )		            
       
    37     {
       
    38     }
       
    39 
       
    40 // -----------------------------------------------------------------------------
       
    41 // TMCETestUIEngineCmdRejectSession::ExecuteL
       
    42 // -----------------------------------------------------------------------------
       
    43 //
       
    44 EXPORT_C void TMCETestUIEngineCmdRingingSession::ExecuteL()
       
    45 	{
       
    46 
       
    47 	iInSession.InSession().RingL();
       
    48 	iEngine.EngineStateChangedL();
       
    49      /*  	CMCETestUIQuestionSingleSelection* question = 
       
    50 	    CMCETestUIQuestionSingleSelection::NewLC();
       
    51 	    
       
    52 	question->SetCaptionL( KMiscIncomingSession );
       
    53 	
       
    54 	question->AddChoiceL( KUserQuestionOptionReject );
       
    55 	question->AddChoiceL( KUserQuestionOptionRejectWithCustomReason );
       
    56 	
       
    57 	TInt index = iEngine.AskQuestionL( *question );
       
    58 	
       
    59 	CleanupStack::PopAndDestroy( question );
       
    60 	
       
    61 	if ( index == 0 ) // Reject now
       
    62 	    {
       
    63         iInSession.InSession().RejectL();	    
       
    64 	    }
       
    65 	else if ( index == 1 )
       
    66 	    {
       
    67 	    User::Leave( KErrNotSupported ); // yet...
       
    68 	    }
       
    69 */	}
       
    70 
       
    71 // -----------------------------------------------------------------------------
       
    72 // TMCETestUIEngineCmdRejectSession::Caption
       
    73 // -----------------------------------------------------------------------------
       
    74 //
       
    75 EXPORT_C const TDesC& TMCETestUIEngineCmdRingingSession::Caption() const
       
    76 	{
       
    77 	return KCommandCaptionRingingSession;
       
    78 	}
       
    79 
       
    80 
       
    81 
       
    82 
       
    83 // End of File