fep/aknfep/inc/AknFepUiInputStateCandidateQwertyBaseChinesePhrase.h
changeset 40 2cb9bae34d17
parent 31 f1bdd6b078d1
child 49 37f5d84451bd
equal deleted inserted replaced
31:f1bdd6b078d1 40:2cb9bae34d17
     1 /*
       
     2 * Copyright (c)  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 
       
    20 
       
    21 
       
    22 
       
    23 
       
    24 
       
    25 
       
    26 
       
    27 
       
    28 
       
    29 #ifndef T_AKNFEPUIINPUTSTATECANDIDATEQWERTYBASECHINESEPHRASE_H
       
    30 #define T_AKNFEPUIINPUTSTATECANDIDATEQWERTYBASECHINESEPHRASE_H
       
    31 
       
    32 #include "AknFepUiInputStateChineseBase.h"
       
    33 #include <PtiDefs.h>
       
    34 
       
    35 /**
       
    36  * key struct.
       
    37  * @since S60 v3.2.3
       
    38  */
       
    39 struct TMiniQwertyKeyMap
       
    40     {
       
    41     TUint16 iValue;
       
    42     TInt iKeyCode;
       
    43     };
       
    44 
       
    45 /**
       
    46  * Tone mark struct.
       
    47  * @since S60 v3.2.3
       
    48  */
       
    49 struct TMiniQwertyToneMap
       
    50     {
       
    51     TUint16 iValue;
       
    52     TInt iInputTone;
       
    53     };
       
    54 
       
    55 class TAknFepInputStateCandidateQwertyBaseChinesePhrase : public TAknFepInputStateChineseBase
       
    56     {
       
    57 public:
       
    58     /**
       
    59      * Handling Command events.
       
    60      * This Method is called by CAknFepUIManagerJapanese.
       
    61      *
       
    62      * @param aCommandId Command ID value
       
    63      */
       
    64     void HandleCommandL( TInt aCommandId );
       
    65 protected:
       
    66     TAknFepInputStateCandidateQwertyBaseChinesePhrase(MAknFepUIManagerStateInterface* aOwner,
       
    67                                     MAknFepUICtrlContainerChinese* aUIContainer);
       
    68 
       
    69     TBool HandleKeyL(TInt aKey, TKeyPressLength aLength);
       
    70 
       
    71     TBool HandleHorizontalNavigation(TInt aKey);
       
    72     TBool HandleVerticalNavigation(TInt aKey);
       
    73 #ifdef RD_INTELLIGENT_TEXT_INPUT
       
    74     /**
       
    75      * Check the select candidate numeric key is valid or not
       
    76      * @since S60 v3.2
       
    77      * @return ETure if the select number is valid ,others is EFalse
       
    78      */
       
    79     TBool  MapKeyToIndexSelectCandidate( TInt aKey,TInt& aIndex );
       
    80 #endif
       
    81     
       
    82     inline TInt MapKeyToIndex(TInt aKey);
       
    83     void UpdateIndicator();
       
    84     void GetNewCandidatesL(const TDesC& aSource, RPointerArray<HBufC>& aList);
       
    85     };
       
    86 
       
    87 inline TInt TAknFepInputStateCandidateQwertyBaseChinesePhrase::MapKeyToIndex(TInt aKey)
       
    88     {
       
    89     TInt index = aKey - EPtiKey0; // get zero-based value first
       
    90     return !index ? 9 : --index; // map it for one-based keys...
       
    91     }
       
    92 
       
    93 #endif //T_AKNFEPUIINPUTSTATECANDIDATEQWERTYBASECHINESEPHRASE_H
       
    94 
       
    95 // End of file