uifw/AvKon/tsrc/bc/bctestdom3.2/bctestdomavkonpsln/src/bctestdomavkonpslnappui.cpp
changeset 21 558113899881
parent 14 3320e4e6e8bb
child 22 75713bee6484
child 33 b3425bf29f82
equal deleted inserted replaced
14:3320e4e6e8bb 21:558113899881
     1 /*
       
     2 * Copyright (c) 2007 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:  ?Description
       
    15 *
       
    16 */
       
    17 
       
    18 
       
    19 #include <avkon.hrh>
       
    20 #include <aknsutils.h>
       
    21 
       
    22 #include "bctestdomavkonpslnappui.h"
       
    23 #include "bctestdomavkonpsln.hrh"
       
    24 #include "bctestdomavkonpslnview.h"
       
    25 #include "bctestutil.h"
       
    26 #include "bctestdomakncase.h"
       
    27 #include "bctestdomeikcase.h"
       
    28 #include "bctestdomfindcase.h"
       
    29 #include "bctestdomjplangcase.h"
       
    30 #include "bctestdompslncase.h"
       
    31 
       
    32 
       
    33 // ============================= MEMBER FUNCTIONS ============================
       
    34 
       
    35 // ---------------------------------------------------------------------------
       
    36 // constructor do nothing
       
    37 // ---------------------------------------------------------------------------
       
    38 //
       
    39 CBCTestDomAvkonPslnAppUi::CBCTestDomAvkonPslnAppUi()
       
    40     {
       
    41     }
       
    42 
       
    43 // ---------------------------------------------------------------------------
       
    44 // symbian 2nd phase constructor
       
    45 // ---------------------------------------------------------------------------
       
    46 //
       
    47 void CBCTestDomAvkonPslnAppUi::ConstructL()
       
    48     {
       
    49     BaseConstructL();
       
    50     AknsUtils::SetAvkonSkinEnabledL( ETrue );
       
    51 
       
    52     // init test util
       
    53     iTestUtil = CBCTestUtil::NewL();
       
    54 
       
    55     // init view
       
    56     CBCTestDomAvkonPslnView* view = CBCTestDomAvkonPslnView::NewL( iTestUtil );
       
    57     CleanupStack::PushL( view );
       
    58     AddViewL( view );
       
    59     CleanupStack::Pop( view );    
       
    60     
       
    61     ActivateLocalViewL( view->Id() );
       
    62 
       
    63     // Add test case here.
       
    64     iTestUtil->AddTestCaseL( CBCTestDomAknCase::NewL( view->Container() ),
       
    65         _L( "domakn test case" ) );
       
    66         
       
    67     iTestUtil->AddTestCaseL( CBCTestDomEikCase::NewL( view->Container() ),
       
    68         _L( "domeik test case" ) );
       
    69     
       
    70     iTestUtil->AddTestCaseL( CBCTestDomFindCase::NewL( view->Container() ),
       
    71         _L( "domfind test case" ) );
       
    72     
       
    73     iTestUtil->AddTestCaseL( CBCTestDomJPLangCase::NewL( view->Container() ),
       
    74         _L( "domjplang test case" ) );
       
    75         
       
    76     iTestUtil->AddTestCaseL( CBCTestDomPslnCase::NewL( view->Container() ),
       
    77         _L( "dompsln test case" ) );
       
    78     }
       
    79     
       
    80 
       
    81 // ---------------------------------------------------------------------------
       
    82 // CBCTestDomAvkonPslnAppUi::~CBCTestDomAvkonPslnAppUi()
       
    83 // Destructor.
       
    84 // ---------------------------------------------------------------------------
       
    85 //
       
    86 CBCTestDomAvkonPslnAppUi::~CBCTestDomAvkonPslnAppUi()
       
    87     { 
       
    88     delete iTestUtil;
       
    89     }
       
    90 
       
    91 // ---------------------------------------------------------------------------
       
    92 // handle menu command events
       
    93 // ---------------------------------------------------------------------------
       
    94 //
       
    95 void CBCTestDomAvkonPslnAppUi::HandleCommandL( TInt aCommand )
       
    96     {
       
    97     switch ( aCommand )
       
    98         {
       
    99         case EAknSoftkeyBack:
       
   100         case EEikCmdExit:
       
   101             {
       
   102             Exit();
       
   103             return;
       
   104             }
       
   105         default:
       
   106             break;
       
   107         }    
       
   108     }
       
   109 
       
   110 // End of File