equal
deleted
inserted
replaced
29 #include <QGraphicsProxyWidget> |
29 #include <QGraphicsProxyWidget> |
30 #include <QGraphicsView> |
30 #include <QGraphicsView> |
31 #include <hbinputmethod.h> |
31 #include <hbinputmethod.h> |
32 #include <hbinputmethod_p.h> |
32 #include <hbinputmethod_p.h> |
33 #include <hbinputsettingproxy.h> |
33 #include <hbinputsettingproxy.h> |
|
34 #include <hbinputmethodnull_p.h> |
34 |
35 |
35 /*! |
36 /*! |
36 @alpha |
37 @alpha |
37 @hbcore |
38 @hbcore |
38 \class HbInputContextProxy |
39 \class HbInputContextProxy |
111 /*! |
112 /*! |
112 \internal |
113 \internal |
113 \reimp |
114 \reimp |
114 */ |
115 */ |
115 bool HbInputContextProxy::filterEvent(const QEvent *event) |
116 bool HbInputContextProxy::filterEvent(const QEvent *event) |
116 { |
117 { |
117 if (mTarget) { |
118 if (mTarget) { |
118 bool focusLocked = mTarget->d_func()->mFocusLocked; |
119 bool focusLocked = mTarget->d_func()->mFocusLocked; |
119 if (event->type() == QEvent::CloseSoftwareInputPanel && !focusLocked) { |
120 if (event->type() == QEvent::CloseSoftwareInputPanel && !focusLocked) { |
120 setInputFrameworkFocus(0); |
121 setInputFrameworkFocus(0); |
121 return true; |
122 return true; |
163 if (Qt::Key_unknown == keyEvent->key()) { |
164 if (Qt::Key_unknown == keyEvent->key()) { |
164 return false; |
165 return false; |
165 } |
166 } |
166 } |
167 } |
167 return mTarget->filterEvent(event); |
168 return mTarget->filterEvent(event); |
|
169 } else { |
|
170 if (event->type() == QEvent::RequestSoftwareInputPanel) { |
|
171 // There is no mTarget. It means that someone is displaying something before |
|
172 // the input framework was initialized. Acknowledge the situation so that |
|
173 // the initializer knows to resend it. See HbApplication::initialize() |
|
174 // method. The empty proxy is installed there. |
|
175 HbInputMethodNull::Instance()->setDelayedPanelRequest(true); |
|
176 return true; |
|
177 } |
168 } |
178 } |
169 |
179 |
170 return false; |
180 return false; |
171 } |
181 } |
172 |
182 |