23 #include <s32mem.h> |
23 #include <s32mem.h> |
24 #include <barsread.h> |
24 #include <barsread.h> |
25 |
25 |
26 #include <aknlayoutscalable_apps.cdl.h> |
26 #include <aknlayoutscalable_apps.cdl.h> |
27 #include <aknlayoutscalable_avkon.cdl.h> |
27 #include <aknlayoutscalable_avkon.cdl.h> |
28 #include <AknLayoutDef.h> |
28 #include <aknlayoutdef.h> |
29 #include <AknUtils.h> |
29 #include <aknutils.h> |
30 #include <AknsUtils.h> |
30 #include <aknsutils.h> |
31 #include <AknIconUtils.h> |
31 #include <akniconutils.h> |
32 #include <aknfeppeninputenums.h> |
32 #include <aknfeppeninputenums.h> |
33 #include <AknFepGlobalEnums.h> |
33 #include <aknfepglobalenums.h> |
34 |
34 |
35 #include <peninputlayout.h> |
35 #include <peninputlayout.h> |
36 #include <peninputrepeatbutton.h> |
36 #include <peninputrepeatbutton.h> |
37 #include <peninputmultiimagebutton.h> |
|
38 #include <peninputpluginutils.h> |
|
39 |
37 |
40 #include "hbufcarrayar.h" |
38 #include "hbufcarrayar.h" |
41 #include "peninputfingerhwrarevent.h" |
39 #include "peninputfingerhwrarevent.h" |
42 #include "peninputfingerhwrarcontrolid.h" |
40 #include "peninputfingerhwrarcontrolid.h" |
43 #include "peninputfingerhwrarstoreconstants.h" |
41 #include "peninputfingerhwrarstoreconstants.h" |
89 // --------------------------------------------------------------------------- |
87 // --------------------------------------------------------------------------- |
90 // |
88 // |
91 void CPeninputArabicFingerHwrSymbolTable::OpenSymbolTable() |
89 void CPeninputArabicFingerHwrSymbolTable::OpenSymbolTable() |
92 { |
90 { |
93 CapturePointer( ETrue ); |
91 CapturePointer( ETrue ); |
94 iPopupVisible = ETrue; |
92 iPopupVisible = ETrue; |
95 iPointerMoveBack = EFalse; |
|
96 Draw(); |
|
97 UpdateArea(iRect ); |
|
98 UiLayout()->LockArea(UiLayout()->Rect(),this); |
93 UiLayout()->LockArea(UiLayout()->Rect(),this); |
99 } |
94 NavigatePage(0,EPagePosPageNo); |
|
95 } |
100 |
96 |
101 // --------------------------------------------------------------------------- |
97 // --------------------------------------------------------------------------- |
102 // cancel the popup. |
98 // cancel the popup. |
103 // --------------------------------------------------------------------------- |
99 // --------------------------------------------------------------------------- |
104 // |
100 // |
105 void CPeninputArabicFingerHwrSymbolTable::CloseSymbolTable() |
101 void CPeninputArabicFingerHwrSymbolTable::CloseSymbolTable() |
106 { |
102 { |
107 CapturePointer( EFalse ); |
103 CapturePointer( EFalse ); |
108 iPenDownCtrl = NULL; |
|
109 iPopupVisible = EFalse; |
104 iPopupVisible = EFalse; |
110 UiLayout()->UnLockArea(UiLayout()->Rect(),this); |
105 UiLayout()->UnLockArea(UiLayout()->Rect(),this); |
111 } |
106 } |
112 |
107 |
113 // --------------------------------------------------------------------------- |
108 // --------------------------------------------------------------------------- |
126 CFepUiBaseCtrl* CPeninputArabicFingerHwrSymbolTable::HandlePointerDownEventL( |
121 CFepUiBaseCtrl* CPeninputArabicFingerHwrSymbolTable::HandlePointerDownEventL( |
127 const TPoint& aPoint ) |
122 const TPoint& aPoint ) |
128 { |
123 { |
129 CancelPointerDownL(); |
124 CancelPointerDownL(); |
130 CFepUiBaseCtrl* ctrl = CControlGroup::HandlePointerDownEventL( aPoint ); |
125 CFepUiBaseCtrl* ctrl = CControlGroup::HandlePointerDownEventL( aPoint ); |
131 iPenDownCtrl = ctrl; |
126 |
132 |
|
133 if(!ctrl) |
127 if(!ctrl) |
134 { |
128 { |
135 ReportEvent(EHwrEventOutsideEvent); |
129 ReportEvent(EHwrEventOutsideEvent); |
136 } |
130 } |
137 else |
131 else |
138 { |
132 { |
139 ctrl->Draw(); |
|
140 ctrl->UpdateArea(ctrl->Rect(),EFalse); |
133 ctrl->UpdateArea(ctrl->Rect(),EFalse); |
141 } |
134 } |
142 |
135 |
143 return ctrl; |
136 return ctrl; |
144 } |
137 } |
169 const TPoint& aPoint ) |
161 const TPoint& aPoint ) |
170 { |
162 { |
171 CFepUiBaseCtrl* ctrl = CControlGroup::HandlePointerMoveEventL( aPoint ); |
163 CFepUiBaseCtrl* ctrl = CControlGroup::HandlePointerMoveEventL( aPoint ); |
172 if(ctrl) |
164 if(ctrl) |
173 { |
165 { |
174 ctrl->Draw(); |
|
175 ctrl->UpdateArea(ctrl->Rect(),EFalse); |
166 ctrl->UpdateArea(ctrl->Rect(),EFalse); |
176 iPointerMoveBack = ETrue; |
|
177 } |
167 } |
178 else |
168 else |
179 { |
169 { |
180 if(iPointerMoveBack) |
170 CControlGroup::HandlePointerLeave(aPoint); |
181 { |
171 UpdateArea(iRect,EFalse); |
182 if(iPenDownCtrl) |
|
183 { |
|
184 iPenDownCtrl->HandlePointerLeave(aPoint); |
|
185 } |
|
186 iPointerMoveBack = EFalse; |
|
187 } |
|
188 } |
172 } |
189 |
173 |
190 return ctrl; |
174 return ctrl; |
191 } |
175 } |
192 |
176 |
193 void CPeninputArabicFingerHwrSymbolTable::HandlePointerLeave(const TPoint& aPoint) |
|
194 { |
|
195 CControlGroup::HandlePointerLeave(aPoint); |
|
196 Draw(); |
|
197 UpdateArea(Rect(),EFalse); |
|
198 } |
|
199 // --------------------------------------------------------------------------- |
177 // --------------------------------------------------------------------------- |
200 // C++ constructor. |
178 // C++ constructor. |
201 // --------------------------------------------------------------------------- |
179 // --------------------------------------------------------------------------- |
202 // |
180 // |
203 CPeninputArabicFingerHwrSymbolTable::CPeninputArabicFingerHwrSymbolTable( |
181 CPeninputArabicFingerHwrSymbolTable::CPeninputArabicFingerHwrSymbolTable( |
366 } |
344 } |
367 |
345 |
368 void CPeninputArabicFingerHwrSymbolTable::OnActivate() |
346 void CPeninputArabicFingerHwrSymbolTable::OnActivate() |
369 { |
347 { |
370 CControlGroup::OnActivate(); |
348 CControlGroup::OnActivate(); |
371 if(IsPopup()) |
349 /*if(IsPopup()) |
372 { |
350 { |
373 CapturePointer( ETrue ); |
351 CapturePointer( ETrue ); |
374 NavigatePage(0,EPagePosPageNo); |
352 NavigatePage(0,EPagePosPageNo); |
375 } |
353 }*/ |
376 } |
354 } |
377 |
355 |
378 void CPeninputArabicFingerHwrSymbolTable::LoadVkbKeyImageL(TInt aResId, const TSize& aKeySize) |
356 void CPeninputArabicFingerHwrSymbolTable::LoadVkbKeyImageL(TInt aResId, const TSize& aKeySize) |
379 { |
357 { |
380 TResourceReader reader; |
358 TResourceReader reader; |
612 |
588 |
613 // --------------------------------------------------------------------------- |
589 // --------------------------------------------------------------------------- |
614 // update feedback state of all virtual keys. |
590 // update feedback state of all virtual keys. |
615 // --------------------------------------------------------------------------- |
591 // --------------------------------------------------------------------------- |
616 // |
592 // |
617 void CPeninputArabicFingerHwrSymbolTable::UpdateAllVirtualKeysFeedback( TInt aType ) |
593 void CPeninputArabicFingerHwrSymbolTable::UpdateAllVirtualKeysFeedback() |
618 { |
594 { |
619 TBool isSctpad = ( aType == EFingerHwrSymbolRange ) ? ETrue : EFalse; |
|
620 |
|
621 //update sctpad keys |
595 //update sctpad keys |
622 TInt keyCount = iMutiPageKeypad->KeyArray().Count(); |
596 TInt keyCount = iMutiPageKeypad->KeyArray().Count(); |
623 TInt pageSize = iMutiPageKeypad->PageSize(); |
597 TInt pageSize = iMutiPageKeypad->PageSize(); |
624 TInt curPage = iMutiPageKeypad->CurPageIndex(); |
598 TInt curPage = iMutiPageKeypad->CurPageIndex(); |
625 for ( TInt i = 0; i < keyCount; i++ ) |
599 for ( TInt i = 0; i < keyCount; i++ ) |
626 { |
600 { |
627 CVirtualKey* vk = iMutiPageKeypad->KeyArray()[i]; |
601 CVirtualKey* vk = iMutiPageKeypad->KeyArray()[i]; |
628 TInt page = i / pageSize; |
602 TInt page = i / pageSize; |
629 TBool enable = !vk->Dimmed() && isSctpad && ( page == curPage ); |
603 TBool enable = !vk->Dimmed() && ( page == curPage ); |
630 iMutiPageKeypad->EnableKeyFeedback( vk, enable ); |
604 iMutiPageKeypad->EnableKeyFeedback( vk, enable ); |
631 } |
605 } |
632 } |
606 } |
|
607 |
633 // End Of File |
608 // End Of File |