fep/aknfep/inc/aknfepuiinputstatezhuyinphrasecreationbase.h
changeset 36 a7632c26d895
parent 35 0f326f2e628e
child 42 b3eaa440ab06
equal deleted inserted replaced
35:0f326f2e628e 36:a7632c26d895
     1 /*
       
     2 * Copyright (c) 2008 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  *      Provides the TAknFepInputStateEntryZhuyinPhraseCreation methods.
       
    16  *
       
    17 */
       
    18 
       
    19 
       
    20 
       
    21 
       
    22 
       
    23 
       
    24 
       
    25 
       
    26 
       
    27 
       
    28 
       
    29 
       
    30 #ifndef T_AKNFEPINPUTSTATEZHUYINPHRASECREATIONBASE_H
       
    31 #define T_AKNFEPINPUTSTATEZHUYINPHRASECREATIONBASE_H
       
    32 
       
    33 #include "AknFepUiInputStateCandidateBase.h"
       
    34 
       
    35 class TAknFepInputStateZhuyinPhraseCreationBase : public TAknFepInputStateCandidateBase
       
    36     {
       
    37 public:
       
    38     
       
    39     /**
       
    40      * C++ constructor.
       
    41      * 
       
    42      * @since S60 v5.0.
       
    43      * @return self object.
       
    44      */  
       
    45     TAknFepInputStateZhuyinPhraseCreationBase(
       
    46                                     MAknFepUIManagerStateInterface* aOwner,
       
    47                                     MAknFepUICtrlContainerChinese* aUIContainer);
       
    48     
       
    49     /**
       
    50      * Add keystroke.
       
    51      * 
       
    52      * @param aKey the input keystroke.
       
    53      * @since S60 v5.0.
       
    54      * @return ETrue if that the key can add to the current keystroke, EFalse others.
       
    55      */            
       
    56     TBool AddKeystrokeL( TInt aKey );
       
    57     
       
    58     /**
       
    59      * Add tone mark.
       
    60      * 
       
    61      * @since S60 v5.0.
       
    62      * @return ETrue if that the key can add to the current keystroke, EFalse others.
       
    63      */            
       
    64     TBool AddToneMarkL(); 
       
    65     
       
    66     /**
       
    67      * Get the candidate info and refresh ui.
       
    68      * 
       
    69      * @since S60 v5.0.
       
    70      * @return ETrue if get candidate sucessful, EFalse others.
       
    71      */            
       
    72     TBool UpdateEEPContent();
       
    73     
       
    74     /**
       
    75      * Check the key stroke group more than max.
       
    76      * 
       
    77      * @since S60 v5.0
       
    78      * 
       
    79      * @return value that more than max begine position.
       
    80      */
       
    81     TInt BegPosOfMoreThanSeven();
       
    82     
       
    83     /**
       
    84      * Check the key stroke group more than max.
       
    85      * 
       
    86      * @since S60 v5.0
       
    87      * @param aBegPos that more than max begine position.
       
    88      * @return none.
       
    89      */
       
    90     void HighlightMoreThanSeven( TInt aBegPos );
       
    91     
       
    92     /**
       
    93      * Check the keystroke count.
       
    94      * 
       
    95      * @since S60 v5.0.
       
    96      * @param aIndex the index of keystroke.
       
    97      * @param aChineseCount the chinese character count.
       
    98      * @param aSymbol the zhuyinsymbol.
       
    99      * @param aZhuyinSymbol the zhuyin symbol array.
       
   100      * @return ETure if keystroke count is not more than max,EFalse others.
       
   101      */
       
   102     TBool ReplaceKeystrokeL( 
       
   103                           TInt aIndex, 
       
   104                           TInt aChineseCount,
       
   105                           const TDesC& aSymbol, 
       
   106                           CDesCArrayFlat* aZhuyinSymbol );
       
   107     
       
   108     /**
       
   109      * Update Selection
       
   110      *
       
   111      * @since S60 v5.0
       
   112      * @param aSelection the index of selecion.
       
   113      * @return None.
       
   114      */ 
       
   115     void RefreshUI();
       
   116     
       
   117     /**
       
   118      * Update indicator
       
   119      *
       
   120      * @since S60 v5.0
       
   121      * @return None.
       
   122      */
       
   123     void UpdateIndicator();
       
   124     
       
   125     void HandleCommandL(TInt /*aCommandId*/);
       
   126     
       
   127     TBool DeleteZhuyinSymbolOrChinese();
       
   128     
       
   129     
       
   130     /**
       
   131      * Change CBA.
       
   132      *
       
   133      * @since S60 v5.0.
       
   134      * @return None.
       
   135      */
       
   136     void ChangeCbaL();
       
   137     
       
   138 private:
       
   139     
       
   140     /**
       
   141      * Check the keystroke count.
       
   142      * 
       
   143      * @since S60 v5.0.
       
   144      * @param aChineseCount the chinese character count.
       
   145      * @param aZhuyinSymbol the zhuyin symbol array.
       
   146      * @return ETure if keystroke count is not more than max,EFalse others.
       
   147      */
       
   148     TBool CheckKeystrokeCountL( TInt aChineseCount, CDesCArrayFlat* aZhuyinSymbol );
       
   149     
       
   150     void CheckShowInfo( TDes& aOutDes, CDesCArrayFlat* aZhuyinSymbol );
       
   151     
       
   152     void DeleteSeparatorWhenInvaild( TDes& aDes );
       
   153 
       
   154     };
       
   155 
       
   156 #endif /*T_AKNFEPINPUTSTATEZHUYINPHRASECREATIONBASE_H*/
       
   157 
       
   158 // End of file