44 |
44 |
45 public: |
45 public: |
46 HbInputMethod(); |
46 HbInputMethod(); |
47 virtual ~HbInputMethod(); |
47 virtual ~HbInputMethod(); |
48 |
48 |
49 static bool initializeFramework(QApplication& app); |
49 static bool initializeFramework(QApplication &app); |
50 static void forceUnfocus(); |
50 static void forceUnfocus(); |
51 static HbInputMethod* activeInputMethod(); |
51 static HbInputMethod *activeInputMethod(); |
52 static QList<HbInputMethodDescriptor> listCustomInputMethods(); |
52 static QList<HbInputMethodDescriptor> listCustomInputMethods(); |
53 |
53 |
54 virtual void focusReceived(); |
54 virtual void focusReceived(); |
55 virtual void focusLost(bool focusSwitch = true); |
55 virtual void focusLost(bool focusSwitch = true); |
56 |
56 |
57 bool isActiveMethod() const; |
57 bool isActiveMethod() const; |
58 |
58 |
59 HbInputFocusObject* focusObject() const; |
59 HbInputFocusObject *focusObject() const; |
60 void setFocusObject(HbInputFocusObject* focusObject); |
60 void setFocusObject(HbInputFocusObject *focusObject); |
61 |
61 |
62 void lockFocus(); |
62 void lockFocus(); |
63 void unlockFocus(); |
63 void unlockFocus(); |
64 |
64 |
65 // From QInputContext (do not override). |
65 // From QInputContext (do not override). |
66 void widgetDestroyed(QWidget* widget); |
66 void widgetDestroyed(QWidget *widget); |
67 void setFocusWidget(QWidget* widget); |
67 void setFocusWidget(QWidget *widget); |
68 |
68 |
69 HbInputState inputState() const; |
69 HbInputState inputState() const; |
70 |
70 |
71 bool activateState(const HbInputState& state); |
71 bool activateState(const HbInputState &state); |
72 void updateState(); |
72 void updateState(); |
73 void editorRootState(HbInputState &result) const; |
73 void editorRootState(HbInputState &result) const; |
74 bool automaticTextCaseNeeded() const; |
74 bool automaticTextCaseNeeded() const; |
75 bool activateInputMethod(const HbInputMethodDescriptor &inputMethod); |
75 bool activateInputMethod(const HbInputMethodDescriptor &inputMethod); |
76 |
76 |
77 protected: |
77 protected: |
78 virtual void inputStateActivated(const HbInputState& newState); |
78 virtual void inputStateActivated(const HbInputState &newState); |
79 virtual void inputLanguageChanged(const HbInputLanguage &newLanguage); |
79 virtual void inputLanguageChanged(const HbInputLanguage &newLanguage); |
80 virtual void secondaryInputLanguageChanged(const HbInputLanguage &newLanguage); |
80 virtual void secondaryInputLanguageChanged(const HbInputLanguage &newLanguage); |
81 bool stateChangeInProgress() const; |
81 bool stateChangeInProgress() const; |
82 |
82 |
83 HbInputLanguage activeLanguage() const; |
83 HbInputLanguage activeLanguage() const; |
84 |
84 |
85 bool modeAllowedInEditor(HbInputModeType mode) const; |
85 bool modeAllowedInEditor(HbInputModeType mode) const; |
86 void inputStateToEditor(const HbInputState& source); |
86 void inputStateToEditor(const HbInputState &source); |
87 |
87 |
88 void constructLatinState(HbInputState &result) const; |
88 void constructLatinState(HbInputState &result) const; |
89 |
89 |
90 HbInputMethodDescriptor descriptor() const; |
90 HbInputMethodDescriptor descriptor() const; |
91 |
91 |
92 public slots: |
92 public slots: |
93 void globalInputLanguageChanged(const HbInputLanguage &newLanguage); |
93 void globalInputLanguageChanged(const HbInputLanguage &newLanguage); |
94 void globalSecondaryInputLanguageChanged(const HbInputLanguage &newLanguage); |
94 void globalSecondaryInputLanguageChanged(const HbInputLanguage &newLanguage); |
95 void activeKeyboardChanged(HbKeyboardType newKeyboard); |
95 void activeKeyboardChanged(HbKeyboardType newKeyboard); |
96 void orientationChanged(Qt::Orientation orientation); |
96 void orientationChanged(Qt::Orientation orientation); |
97 virtual void orientationAboutToChange(); |
97 virtual void orientationAboutToChange(); |
98 void editorDeleted(QObject *obj); |
98 void editorDeleted(QObject *obj); |
99 |
99 |
100 protected: |
100 protected: |