|
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: |
|
15 * Provides the TAknFepInputStateEntryQwertyWesternPredictive definition. |
|
16 * |
|
17 */ |
|
18 |
|
19 |
|
20 |
|
21 |
|
22 |
|
23 |
|
24 |
|
25 |
|
26 |
|
27 |
|
28 |
|
29 |
|
30 #ifndef __AKN_FEP_UI_INPUT_STATE_ENTRY_QWERTY_WESTERN_PREDICTIVE_H__ |
|
31 #define __AKN_FEP_UI_INPUT_STATE_ENTRY_QWERTY_WESTERN_PREDICTIVE_H__ |
|
32 |
|
33 #include "AknFepUiInputStateBase.h" |
|
34 |
|
35 class TAknFepInputStateEntryQwertyWesternPredictive : public TAknFepInputStateBase |
|
36 { |
|
37 public: |
|
38 /** |
|
39 * Constructor |
|
40 * @param aOwner The UI manager that owns this input state |
|
41 */ |
|
42 TAknFepInputStateEntryQwertyWesternPredictive(MAknFepUIManagerStateInterface* aOwner); |
|
43 |
|
44 /** |
|
45 * The main handler function for the key presses. |
|
46 * @param aKey The key to be handled. This may be either TKeyCode or TStdScanCode value. |
|
47 * @param aLength Tells if the key press is short or long one. |
|
48 */ |
|
49 TBool HandleKeyL(TInt aKey, TKeyPressLength aLength); |
|
50 |
|
51 |
|
52 public: // Functions from MPtiObserver interface |
|
53 /** |
|
54 * Called when last word in the selection list is activated. Not relevant as we use the |
|
55 * candidate popup. |
|
56 */ |
|
57 void LastWordInSelectionList(); |
|
58 |
|
59 /** |
|
60 * Called when the first word in the selection list is activated. Not relevant as we use the |
|
61 * candidate popup. |
|
62 */ |
|
63 void FirstWordInSelectionList(); |
|
64 |
|
65 /** |
|
66 * Called when the Chr multitap timer expires. The case should be updated at that time. |
|
67 */ |
|
68 void KeyTimerExpired(); |
|
69 |
|
70 protected: |
|
71 /** |
|
72 * Sets the shift state of the PtiEngine according the shift and chr states of the Fep. |
|
73 * @param aKey The with which the shift state is used. This is needed because shift |
|
74 * works differently with letter keys than with numbers and punctuation. |
|
75 */ |
|
76 void HandleShiftState(TInt aKey); |
|
77 |
|
78 /** |
|
79 * Handles keys which cause the active word to be committed (like enter, space, tab,...). |
|
80 * @param aKey The key to be handled. |
|
81 */ |
|
82 TBool HandleWordBreakingKeysL(TInt aKey); |
|
83 |
|
84 /** |
|
85 * Handles the "normal" keys which (may) cause some character to be appended to the current word. |
|
86 * @param aKey The key to be handled. |
|
87 */ |
|
88 TBool HandleQwertyKeysL(TInt aKey); |
|
89 |
|
90 /** |
|
91 * Handles the keys which cause cursor movements (arrows, backspace). |
|
92 * @param aKey The key to be handled |
|
93 * @param aLength The key press length. |
|
94 */ |
|
95 TBool HandleNaviKeysL(TInt aKey, TKeyPressLength aLength); |
|
96 }; |
|
97 |
|
98 #endif //__AKN_FEP_UI_INPUT_STATE_ENTRY_QWERTY_WESTERN_PREDICTIVE_H__ |
|
99 |
|
100 // End of file |