phoneapp/phoneuiutils/inc/tphonecmdparamKeycapture.h
changeset 0 5f000ab63145
equal deleted inserted replaced
-1:000000000000 0:5f000ab63145
       
     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: 
       
    15 *   See class description.
       
    16 *
       
    17 */
       
    18 
       
    19 
       
    20 #ifndef __TPHONECMDPARAMKEYCAPTURE_H
       
    21 #define __TPHONECMDPARAMKEYCAPTURE_H
       
    22 
       
    23 //  INCLUDES
       
    24 
       
    25 #include <e32keys.h>
       
    26 #include "tphonecommandparam.h"
       
    27 
       
    28 // DATA TYPES
       
    29 enum TPhoneCaptureType
       
    30 {
       
    31     EPhoneKeyEvent,
       
    32     EPhoneKeyUpAndDownEvents,
       
    33     EPhoneKeyAllEvents
       
    34 };
       
    35 
       
    36 // CLASS DECLARATION
       
    37 
       
    38 /**
       
    39 *  A parameter class for key capture information.
       
    40 */
       
    41 class TPhoneCmdParamKeyCapture : public TPhoneUICommandParam
       
    42     {   
       
    43     public:  
       
    44         
       
    45         /**
       
    46         * C++ default constructor.
       
    47         */
       
    48         IMPORT_C TPhoneCmdParamKeyCapture();
       
    49 
       
    50     public: 
       
    51         
       
    52         /**
       
    53         * Sets the key scan code.
       
    54         * @param aKey is the key scan code
       
    55         */
       
    56         IMPORT_C void SetKey( TStdScanCode aKey );
       
    57 
       
    58         
       
    59         /**
       
    60         * Sets the key code.
       
    61         * @param aKeyCode is the key code
       
    62         */
       
    63         IMPORT_C void SetKeyCode( TKeyCode aKeyCode );
       
    64 
       
    65         /**
       
    66         * Sets the key capture type.
       
    67         * @param aCaptureType is the key capture type
       
    68         */
       
    69         IMPORT_C void SetCaptureType( TPhoneCaptureType aCaptureType );
       
    70 
       
    71         /**
       
    72         * Returns the key scan code.
       
    73         * @return Returns the key scan code
       
    74         */
       
    75         IMPORT_C TStdScanCode Key() const;
       
    76 
       
    77         /**
       
    78         * Returns the key code.
       
    79         * @return Returns the key code
       
    80         */
       
    81         IMPORT_C TKeyCode KeyCode() const;
       
    82 
       
    83         /**
       
    84         * Returns the key capture type
       
    85         * @return Returns the key capture type
       
    86         */
       
    87         IMPORT_C TPhoneCaptureType CaptureType() const;
       
    88 
       
    89     private:    
       
    90         
       
    91         /**
       
    92         * Key scan code
       
    93         */
       
    94         TStdScanCode iKey;
       
    95 
       
    96         /**
       
    97         * Key code
       
    98         */
       
    99         TKeyCode iKeyCode;
       
   100 
       
   101         /**
       
   102         * Key capture type
       
   103         */
       
   104         TPhoneCaptureType iCaptureType;
       
   105     };
       
   106 
       
   107 #endif // __TPHONECMDPARAMKEYCAPTURE_H   
       
   108             
       
   109 // End of File