omaprovisioning/provisioning/ProvisioningBC/Src/CWPCodeQueryDialog.cpp
changeset 51 2e64dc50f295
parent 50 a36219ae6585
child 52 830bd228f4f6
equal deleted inserted replaced
50:a36219ae6585 51:2e64dc50f295
     1 /*
       
     2 * Copyright (c) 2002 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: 
       
    15 *     Sortable pair of strings.
       
    16 *
       
    17 */
       
    18 
       
    19 
       
    20 // INCLUDE FILES
       
    21 #include "CWPCodeQueryDialog.h"
       
    22 
       
    23 // ============================ MEMBER FUNCTIONS ===============================
       
    24 
       
    25 
       
    26 // ----------------------------------------------------------------------------
       
    27 // CCodeQueryDialog::CCodeQueryDialog()
       
    28 // C++ constructor
       
    29 // ----------------------------------------------------------------------------
       
    30 //
       
    31 CWPCodeQueryDialog::CWPCodeQueryDialog( TDes& aDataText )
       
    32                                     : CAknTextQueryDialog( aDataText, ENoTone )
       
    33 	{
       
    34 	}
       
    35 
       
    36 
       
    37 // ----------------------------------------------------------------------------
       
    38 // Destructor
       
    39 // ----------------------------------------------------------------------------
       
    40 //
       
    41 CWPCodeQueryDialog::~CWPCodeQueryDialog()
       
    42 	{
       
    43 	}
       
    44 
       
    45 // ----------------------------------------------------------------------------
       
    46 // CWPCodeQueryDialog::OfferKeyEventL
       
    47 // called by framework when any key is pressed
       
    48 // ----------------------------------------------------------------------------
       
    49 //
       
    50 TKeyResponse CWPCodeQueryDialog::OfferKeyEventL( const TKeyEvent& aKeyEvent,
       
    51                                                  TEventCode aType )
       
    52 	{
       
    53 	// '#' key 
       
    54 	if( aKeyEvent.iScanCode == EStdKeyHash  && aType == EEventKeyUp)
       
    55 		{ 
       
    56 		TryExitL( EEikBidOk );
       
    57 		return EKeyWasConsumed;
       
    58 		}
       
    59 	
       
    60 	// '*' key
       
    61 	if ( aKeyEvent.iCode == '*' )
       
    62 		{
       
    63 		return EKeyWasConsumed;
       
    64 		}
       
    65 
       
    66 	return CAknTextQueryDialog::OfferKeyEventL( aKeyEvent, aType );
       
    67 	}
       
    68 
       
    69 // ----------------------------------------------------------------------------
       
    70 // CWPCodeQueryDialog::NeedToDismissQueryL()
       
    71 // Handles '#' key called by CAknTextQueryDialog::OfferKeyEventL()
       
    72 // ----------------------------------------------------------------------------
       
    73 //
       
    74 TBool CWPCodeQueryDialog::NeedToDismissQueryL( const TKeyEvent& /*aKeyEvent*/ )
       
    75 	{
       
    76 	return EFalse;
       
    77 	}
       
    78 
       
    79 // ----------------------------------------------------------------------------
       
    80 // CWPCodeQueryDialog::OkToExitL()
       
    81 // called by framework when the Softkey is pressed
       
    82 // ----------------------------------------------------------------------------
       
    83 //
       
    84 TBool CWPCodeQueryDialog::OkToExitL( TInt aButtonId )
       
    85 	{
       
    86 	return CAknTextQueryDialog::OkToExitL( aButtonId );
       
    87 	}
       
    88 	
       
    89 //  End of File