phoneapp/phoneui2/tsrc/ut_phoneuicommandadapter/cphoneuicontroller_stub.cpp
changeset 36 2eacb6118286
parent 30 ebdbd102c78a
child 37 ba76fc04e6c2
equal deleted inserted replaced
30:ebdbd102c78a 36:2eacb6118286
     1 /*
       
     2 * Copyright (c) 2009 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 of CPhoneUIController class.
       
    15 *
       
    16 */
       
    17 
       
    18 
       
    19 // INCLUDE FILES
       
    20 
       
    21 #include "CPhoneUIController_Stub.h"
       
    22 
       
    23 int m_command;
       
    24 bool m_leave;
       
    25 
       
    26 
       
    27 // ================= MEMBER FUNCTIONS =======================
       
    28 
       
    29 // -----------------------------------------------------------
       
    30 // CPhoneUIController::CPhoneUIController
       
    31 // C++ default constructor can NOT contain any code, that
       
    32 // might leave.
       
    33 // -----------------------------------------------------------
       
    34 //
       
    35 CPhoneUIController_Stub::CPhoneUIController_Stub()  
       
    36     {
       
    37     m_leave = false;	
       
    38     }
       
    39 
       
    40 
       
    41 
       
    42 // -----------------------------------------------------------
       
    43 // Destructor
       
    44 // 
       
    45 // -----------------------------------------------------------
       
    46 
       
    47 CPhoneUIController_Stub::~CPhoneUIController_Stub()
       
    48     {
       
    49 
       
    50     }
       
    51 
       
    52 
       
    53 
       
    54 // ---------------------------------------------------------
       
    55 // CPhoneUIController_Stub::HandleCommandL
       
    56 // ---------------------------------------------------------
       
    57 //
       
    58 TBool CPhoneUIController_Stub::HandleCommandL( TInt aCommand )
       
    59     {
       
    60     m_command = 0;
       
    61     
       
    62     if (m_leave)
       
    63         {
       
    64         User::Leave(KErrArgument);
       
    65         }
       
    66         
       
    67     m_command = aCommand;
       
    68     
       
    69     return ETrue;
       
    70     }
       
    71 
       
    72 // ---------------------------------------------------------
       
    73 // CPhoneUIController_Stub::ProcessCommandL
       
    74 // ---------------------------------------------------------
       
    75 //
       
    76 TBool CPhoneUIController_Stub::ProcessCommandL( TInt /*aCommand*/ )
       
    77     {  
       
    78     return ETrue;
       
    79     }
       
    80 
       
    81 //  End of File