Chromium Code Reviews| Index: ui/views/win/hwnd_message_handler.h |
| diff --git a/ui/views/win/hwnd_message_handler.h b/ui/views/win/hwnd_message_handler.h |
| index f56a7ca05927ae0f5c947899aaeb522ca9db6667..689089fe3eae314af8df9221fb47966e96989e62 100644 |
| --- a/ui/views/win/hwnd_message_handler.h |
| +++ b/ui/views/win/hwnd_message_handler.h |
| @@ -21,6 +21,7 @@ |
| #include "base/win/scoped_gdi_object.h" |
| #include "base/win/win_util.h" |
| #include "ui/accessibility/ax_enums.h" |
| +#include "ui/base/ime/input_method_observer.h" |
| #include "ui/base/ui_base_types.h" |
| #include "ui/base/win/window_event_target.h" |
| #include "ui/events/event.h" |
| @@ -38,6 +39,9 @@ class DirectManipulationHelper; |
| } // namespace gfx |
| namespace ui { |
| +class AXFakeCaretWin; |
| +class InputMethod; |
| +class TextInputClient; |
| class ViewProp; |
| } |
| @@ -119,6 +123,7 @@ const int WM_WINDOWSIZINGFINISHED = WM_USER; |
| // TODO(beng): This object should eventually *become* the WindowImpl. |
| class VIEWS_EXPORT HWNDMessageHandler : |
| public gfx::WindowImpl, |
| + public ui::InputMethodObserver, |
| public ui::WindowEventTarget { |
| public: |
| explicit HWNDMessageHandler(HWNDMessageHandlerDelegate* delegate); |
| @@ -222,6 +227,15 @@ class VIEWS_EXPORT HWNDMessageHandler : |
| HICON GetSmallWindowIcon() const override; |
| LRESULT OnWndProc(UINT message, WPARAM w_param, LPARAM l_param) override; |
| + // Overridden from InputMethodObserver |
| + void OnTextInputTypeChanged(const TextInputClient* client) override {} |
|
dmazzoni
2017/04/27 05:07:32
You should handle this in order to handle the case
|
| + void OnFocus() override {} |
| + void OnBlur() override {} |
| + void OnCaretBoundsChanged(const TextInputClient* client) override; |
| + void OnTextInputStateChanged(const TextInputClient* client) override; |
| + void OnInputMethodDestroyed(const InputMethod* input_method) override; |
|
dmazzoni
2017/04/27 05:07:32
Possibly this too.
See chrome/browser/chromeos/ac
|
| + void OnShowImeIfNeeded() override {} |
| + |
| // Overridden from WindowEventTarget |
| LRESULT HandleMouseMessage(unsigned int message, |
| WPARAM w_param, |
| @@ -685,6 +699,9 @@ class VIEWS_EXPORT HWNDMessageHandler : |
| std::unique_ptr<WindowsSessionChangeObserver> |
| windows_session_change_observer_; |
| + // Some assistive software need to track the location of the caret. |
| + std::unique_ptr<ui::AXFakeCaretWin> ax_fake_caret_; |
| + |
| // This class provides functionality to register the legacy window as a |
| // Direct Manipulation consumer. This allows us to support smooth scroll |
| // in Chrome on Windows 10. |