📄 fepcontrol.h
字号:
#if !defined(__E32BASE_H__)
#include <E32BASE.H>
#endif
#if !defined(__W32STD_H__)
#include <W32STD.H>
#endif
#if !defined(__FRMTLAY_H__)
#include <FRMTLAY.H>
#endif
#if !defined(__COEMAIN_H__)
#include <COEMAIN.H>
#endif
#if !defined(__COECNTRL_H__)
#include <COECNTRL.H>
#endif
#if !defined(__FEPBASE_H__)
#include <FEPBASE.H>
#endif
#if !defined(__FEPITFR_H__)
#include <FEPITFR.H>
#endif
#if !defined(__EIKDIALG_H__)
#include <EIKDIALG.H>
#endif
#if !defined(__AKNLISTS_H__)
#include <AKNLISTS.H>
#endif
#if !defined(__EIKMOBS_H__)
#include <EIKMOBS.H>
#endif
#if !defined(__AKNEDSTSOBS_H__)
#include <AKNEDSTSOBS.H>
#endif
// Forward declarations
class CExampleFep;
class CAknEdwinState;
class CExampleFepMultiTapEngine;
class CAknNavigationControlContainer;
class CAknNavigationDecorator;
class CFepIndicator;
class CExampleFepControl : public CCoeControl, private MFepInlineTextFormatRetriever, MFepPointerEventHandlerDuringInlineEdit
{
private:
//constructor
CExampleFepControl(CExampleFep& aFep);
void ConstructL();
public:
static CExampleFepControl* NewL(CExampleFep& aFep);
~CExampleFepControl();
//From CCoeControl
TKeyResponse OfferKeyEventL(const TKeyEvent& aKeyEvent, TEventCode aType);
// from MFepInlineTextFormatRetriever
virtual void GetFormatOfFepInlineText(TCharFormat& aFormat, TInt& aNumberOfCharactersWithSameFormat, TInt aPositionOfCharacter) const;
// from MFepPointerEventHandlerDuringInlineEdit
virtual void HandlePointerEventInInlineTextL(TPointerEvent::TType aType, TUint aModifiers, TInt aPositionInInlineText);
public: // New methods
TKeyResponse OfferKeyEventInMultiTapModeL(const TKeyEvent& aKeyEvent, TEventCode aType);
TKeyResponse OfferKeyEventInNumericModeL(const TKeyEvent& aKeyEvent, TEventCode aType);
TKeyResponse OfferKeyEventInSecretAlphaModeL(const TKeyEvent& aKeyEvent, TEventCode aType);
void HandleMultiTapModeKeyCodeL(TUint aKeyCode);
void SimulateKeyEventL(TUint aCharacter);
void HandleChangeInFocus();
void HandleChangeInFocusL();
// Start of inline text editing
void StartInlineEditL(MCoeFepAwareTextEditor& aFepAwareTextEditor, const TDesC& aInitialInlineText,
TInt aPositionOfInsertionPointInInlineText, TBool aCursorVisibility);
void CancelInlineEdit(MCoeFepAwareTextEditor& aFepAwareTextEditor);
void UpdateInlineEditL(const TDesC& aNewInlineText, TInt aPositionOfInsertionPointInInlineText);
void CommitInlineEditL(MCoeFepAwareTextEditor& aFepAwareTextEditor, TBool aCursorVisibility);
void ClearBuffer(void);
public: // new methods
void SwitchInputModeL(TUint aInputMode); // For switching input mode
CAknEdwinState* EditorState() const; // Get current Avkon eidtor state
private:
CExampleFep& iFep;
TCoeInputCapabilities iInputCapabilities;
TUint iInputMode;
TUint iPreviousMultiTapKeyCode;
TInt iInsideInlineEditingTransaction; // Flag for editor inline editing
CExampleFepMultiTapEngine* iMultiTapEngine;
TCursorSelection iUncommittedText;
CFepIndicator* iIndicator;
TInt iResId; // For containing the T9 resource ID
};
// End of file
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -