|
1 /* |
|
2 * Copyright (c) 2002-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: Implementation of the hwr ui state |
|
15 * |
|
16 */ |
|
17 |
|
18 |
|
19 // System includes |
|
20 #include <peninputlayoutbasecontrol.h> // EEventVirtualKeyUp, ... |
|
21 #include <peninputcommonlayoutglobalenum.h> // EPeninputLayoutEventBack, ... |
|
22 |
|
23 // user includes |
|
24 #include "peninputhwrarabicstate.h" |
|
25 #include "peninputhwrarabiclayout.h" |
|
26 |
|
27 // constant definition |
|
28 |
|
29 // ======== MEMBER FUNCTIONS ======== |
|
30 |
|
31 // Implementation of Class CPeninputHwrBxAbStateBase |
|
32 |
|
33 // ----------------------------------------------------------------------------- |
|
34 // CPeninputHwrBxAbStateBase::NewL |
|
35 // (other items were commented in a header). |
|
36 // ----------------------------------------------------------------------------- |
|
37 // |
|
38 CPeninputHwrBxAbStateBase* CPeninputHwrBxAbStateBase::NewL(MPeninputUiStateMgr* aUiStateMgr, MPeninputLayoutContext* aContext) |
|
39 { |
|
40 CPeninputHwrBxAbStateBase* self = new ( ELeave ) CPeninputHwrBxAbStateBase(aUiStateMgr,aContext); |
|
41 CleanupStack::PushL(self); |
|
42 self->Construct(); |
|
43 CleanupStack::Pop(self); |
|
44 return self; |
|
45 } |
|
46 |
|
47 // ----------------------------------------------------------------------------- |
|
48 // CPeninputHwrBxAbStateBase::~CPeninputHwrBxAbStateBase |
|
49 // (other items were commented in a header). |
|
50 // ----------------------------------------------------------------------------- |
|
51 // |
|
52 CPeninputHwrBxAbStateBase::~CPeninputHwrBxAbStateBase() |
|
53 { |
|
54 } |
|
55 |
|
56 // ----------------------------------------------------------------------------- |
|
57 // CPeninputHwrBxAbStateBase::HandleControlEvent |
|
58 // (other items were commented in a header). |
|
59 // return False --->iHiraganaKanji->HandleControlEventJpL() by UiLayout |
|
60 // ----------------------------------------------------------------------------- |
|
61 // |
|
62 TBool CPeninputHwrBxAbStateBase::HandleControlEvent(TInt aEventType, const TDesC& aEventData) |
|
63 { |
|
64 if (aEventType == EEventVirtualKeyUp) // pseudo virual key (hwr 1 char) |
|
65 { |
|
66 return HandleVkbEvent(aEventType, aEventData); |
|
67 } |
|
68 else if (aEventType == EPeninputLayoutEventBack) |
|
69 { |
|
70 return HandleBackEvent(aEventType, aEventData); |
|
71 } |
|
72 else if ((aEventType == EPeninputLayoutEventTab) || |
|
73 (aEventType == EPeninputLayoutEventEnter) || |
|
74 (aEventType == EPeninputLayoutEventSpace)) |
|
75 { |
|
76 return HandleEnterSpaceTabEvent(aEventType, aEventData); |
|
77 } |
|
78 else |
|
79 { |
|
80 return EFalse; |
|
81 } |
|
82 } |
|
83 |
|
84 // ----------------------------------------------------------------------------- |
|
85 // CPeninputHwrBxAbStateBase::CPeninputHwrBxAbStateBase |
|
86 // (other items were commented in a header). |
|
87 // ----------------------------------------------------------------------------- |
|
88 // |
|
89 CPeninputHwrBxAbStateBase::CPeninputHwrBxAbStateBase(MPeninputUiStateMgr* aUiStateMgr, MPeninputLayoutContext* aContext) |
|
90 : CPeninputUiStateBase( aUiStateMgr, aContext ) |
|
91 { |
|
92 } |
|
93 |
|
94 // ----------------------------------------------------------------------------- |
|
95 // CPeninputHwrBxAbStateBase::HandleVkbEvent |
|
96 // pseudo virual key (hwr 1 char) |
|
97 // (other items were commented in a header). |
|
98 // ----------------------------------------------------------------------------- |
|
99 // |
|
100 TBool CPeninputHwrBxAbStateBase::HandleVkbEvent(TInt /*aEventType*/, |
|
101 const TDesC& /*aEventData*/) |
|
102 { |
|
103 return ETrue; |
|
104 } |
|
105 |
|
106 // ----------------------------------------------------------------------------- |
|
107 // CPeninputHwrBxAbStateBase::HandleBackEvent |
|
108 // (other items were commented in a header). |
|
109 // ----------------------------------------------------------------------------- |
|
110 // |
|
111 TBool CPeninputHwrBxAbStateBase::HandleBackEvent(TInt /*aEventType*/, |
|
112 const TDesC& /*aEventData*/) |
|
113 { |
|
114 return ETrue; |
|
115 } |
|
116 |
|
117 // ----------------------------------------------------------------------------- |
|
118 // CPeninputHwrBxAbStateBase::HandleEnterSpaceTabEvent |
|
119 // (other items were commented in a header). |
|
120 // ----------------------------------------------------------------------------- |
|
121 // |
|
122 TBool CPeninputHwrBxAbStateBase::HandleEnterSpaceTabEvent(TInt /*aEventType*/, |
|
123 const TDesC& /*aEventData*/) |
|
124 { |
|
125 return ETrue; |
|
126 } |
|
127 |
|
128 // -------------------------------------------------------------------------- |
|
129 // CPeninputHwrBxAbStateBase::HandleControlEventPenL |
|
130 // (other items were commented in a header) |
|
131 // -------------------------------------------------------------------------- |
|
132 // |
|
133 void CPeninputHwrBxAbStateBase::HandleControlEventPenL( TInt /*aEventType*/, |
|
134 const TDesC& /*aEventData*/, CPeninputHwrBxAbLayout& /*aUiLayout*/, TDes& /*aCharCode*/, TBool& aHandled) |
|
135 { |
|
136 aHandled = EFalse; |
|
137 } |
|
138 |
|
139 // End Of File |