33 |
33 |
34 #ifdef RD_TACTILE_FEEDBACK |
34 #ifdef RD_TACTILE_FEEDBACK |
35 #include <touchfeedback.h> |
35 #include <touchfeedback.h> |
36 #include <featmgr.h> |
36 #include <featmgr.h> |
37 #endif //RD_TACTILE_FEEDBACK |
37 #endif //RD_TACTILE_FEEDBACK |
|
38 |
|
39 #include <AknFepGlobalEnums.h> |
|
40 #include <layoutmetadata.cdl.h> |
|
41 #include "peninputtapsettingmanager.h" |
|
42 |
38 // ======== MEMBER FUNCTIONS ======== |
43 // ======== MEMBER FUNCTIONS ======== |
39 |
44 |
40 // --------------------------------------------------------------------------- |
45 // --------------------------------------------------------------------------- |
41 // CFepUiLayout::CFepUiLayout |
46 // CFepUiLayout::CFepUiLayout |
42 // Constructor |
47 // Constructor |
83 iExtension->iTactileSupported = EFalse; |
88 iExtension->iTactileSupported = EFalse; |
84 #endif // RD_TACTILE_FEEDBACK |
89 #endif // RD_TACTILE_FEEDBACK |
85 iExtension->iSkinInstance = AknsUtils::SkinInstance(); |
90 iExtension->iSkinInstance = AknsUtils::SkinInstance(); |
86 iExtension->iTouchFeedbackInstance = MTouchFeedback::Instance(); |
91 iExtension->iTouchFeedbackInstance = MTouchFeedback::Instance(); |
87 iExtension->iDisableDrawing = EFalse; |
92 iExtension->iDisableDrawing = EFalse; |
|
93 |
|
94 TInt inputMode = PenInputType(); |
|
95 TBool isPortraitFSQEnabled = FeatureManager::FeatureSupported( |
|
96 KFeatureIdFfVirtualFullscrPortraitQwertyInput ); |
|
97 |
|
98 //detect real type of two qwerty layout |
|
99 if ( inputMode == EPluginInputModeFSQ && isPortraitFSQEnabled |
|
100 && !Layout_Meta_Data::IsLandscapeOrientation() ) |
|
101 { |
|
102 inputMode = EPluginInputModePortraitFSQ; |
|
103 } |
|
104 |
|
105 //load settings of tap accuracy enhancement |
|
106 LoadTapAccuracySettingsL( inputMode ); |
88 } |
107 } |
89 |
108 |
90 // --------------------------------------------------------------------------- |
109 // --------------------------------------------------------------------------- |
91 // CFepUiLayout::HandleEventL |
110 // CFepUiLayout::HandleEventL |
92 // handle event from window server |
111 // handle event from window server |
472 { |
491 { |
473 iLayoutReady = ETrue; |
492 iLayoutReady = ETrue; |
474 iRootCtrl->OnActivate(); |
493 iRootCtrl->OnActivate(); |
475 #ifdef RD_TACTILE_FEEDBACK |
494 #ifdef RD_TACTILE_FEEDBACK |
476 iExtension->iTactileSupported = FeatureManager::FeatureSupported( KFeatureIdTactileFeedback ); |
495 iExtension->iTactileSupported = FeatureManager::FeatureSupported( KFeatureIdTactileFeedback ); |
477 #endif // RD_TACTILE_FEEDBACK |
496 #endif // RD_TACTILE_FEEDBACK |
|
497 |
|
498 //update pointer event suppressor |
|
499 if ( FeatureManager::FeatureSupported( KFeatureIdFfCapacitiveDisplay ) ) |
|
500 { |
|
501 TPointerEventSuppressorParameters parameters; |
|
502 parameters.iMoveEventMaxMovement = iExtension->iPointerMoveSuppressMaxMovement; |
|
503 parameters.iMoveEventTimeout = iExtension->iPointerMoveSuppressTimeout; |
|
504 parameters.iUpEventMaxMovement = iExtension->iPointerUpSuppressMaxMovement; |
|
505 parameters.iUpEventTimeout = iExtension->iPointerUpSuppressTimeout; |
|
506 |
|
507 TPtrC data( reinterpret_cast<TUint16*>(¶meters), |
|
508 sizeof(TPointerEventSuppressorParameters) / 2 ); |
|
509 |
|
510 SignalOwner( ESignalUpdatePointerSuppressor, data ); |
|
511 } |
478 } |
512 } |
479 |
513 |
480 // --------------------------------------------------------------------------- |
514 // --------------------------------------------------------------------------- |
481 // CFepUiLayout::OnDeActivate |
515 // CFepUiLayout::OnDeActivate |
482 // Response to layout de-activation |
516 // Response to layout de-activation |
921 ptr.Set(reinterpret_cast<const TUint16*>(&aFlag),sizeof(aFlag)/sizeof(TUint16)); |
955 ptr.Set(reinterpret_cast<const TUint16*>(&aFlag),sizeof(aFlag)/sizeof(TUint16)); |
922 |
956 |
923 SignalOwner(ESignalDisableUpdating,ptr); |
957 SignalOwner(ESignalDisableUpdating,ptr); |
924 } |
958 } |
925 |
959 |
|
960 // --------------------------------------------------------------------------- |
|
961 // Get extra response area of key controls. |
|
962 // --------------------------------------------------------------------------- |
|
963 // |
|
964 void CFepUiLayout::GetKeyExtResponseArea( TMargins& aMargins ) |
|
965 { |
|
966 aMargins = iExtension->iKeyExtResponseMargins; |
|
967 } |
|
968 |
|
969 // --------------------------------------------------------------------------- |
|
970 // Get extra response area of button controls. |
|
971 // --------------------------------------------------------------------------- |
|
972 // |
|
973 void CFepUiLayout::GetButtonExtResponseArea( TMargins& aMargins ) |
|
974 { |
|
975 aMargins = iExtension->iButtonExtResponseMargins; |
|
976 } |
|
977 |
|
978 // --------------------------------------------------------------------------- |
|
979 // Load tap accuracy enhancement settings according to the specified input mode. |
|
980 // --------------------------------------------------------------------------- |
|
981 // |
|
982 void CFepUiLayout::LoadTapAccuracySettingsL( TInt alayoutType ) |
|
983 { |
|
984 CPeninputTapSettingManager* manager = CPeninputTapSettingManager::NewL(); |
|
985 |
|
986 manager->Load( alayoutType ); |
|
987 manager->GetPointerMoveSuppressor( iExtension->iPointerMoveSuppressMaxMovement, |
|
988 iExtension->iPointerMoveSuppressTimeout ); |
|
989 |
|
990 manager->GetPointerUpSuppressor( iExtension->iPointerUpSuppressMaxMovement, |
|
991 iExtension->iPointerUpSuppressTimeout ); |
|
992 |
|
993 manager->GetKeyExtResponseArea( iExtension->iKeyExtResponseMargins ); |
|
994 manager->GetButtonExtResponseArea( iExtension->iButtonExtResponseMargins ); |
|
995 |
|
996 delete manager; |
|
997 } |
|
998 |
926 //end of file |
999 //end of file |