Chromium Code Reviews| Index: views/widget/widget_gtk.h |
| diff --git a/views/widget/widget_gtk.h b/views/widget/widget_gtk.h |
| index 39f6de5d95d9a701c3e1fd0c54ed8c565c9dd3b6..8bc1da32e0f0a4229b457872d10da1fa8404dee7 100644 |
| --- a/views/widget/widget_gtk.h |
| +++ b/views/widget/widget_gtk.h |
| @@ -13,6 +13,8 @@ |
| #include "ui/base/x/active_window_watcher_x.h" |
| #include "ui/gfx/size.h" |
| #include "views/focus/focus_manager.h" |
| +#include "views/ime/input_method_delegate.h" |
| +#include "views/ime/input_method_gtk.h" |
| #include "views/widget/native_widget.h" |
| #include "views/widget/widget.h" |
| @@ -41,7 +43,8 @@ class NativeWidgetDelegate; |
| // Widget implementation for GTK. |
| class WidgetGtk : public Widget, |
| public NativeWidget, |
| - public ui::ActiveWindowWatcherX::Observer { |
| + public ui::ActiveWindowWatcherX::Observer, |
| + public internal::InputMethodDelegate { |
| public: |
| // Type of widget. |
| enum Type { |
| @@ -185,6 +188,8 @@ class WidgetGtk : public Widget, |
| virtual void SetNativeCapture() OVERRIDE; |
| virtual void ReleaseNativeCapture() OVERRIDE; |
| virtual bool HasNativeCapture() const OVERRIDE; |
| + virtual InputMethod* GetInputMethodNative() OVERRIDE; |
| + virtual void ReplaceInputMethod(InputMethod* input_method) OVERRIDE; |
| virtual gfx::Rect GetWindowScreenBounds() const OVERRIDE; |
| virtual gfx::Rect GetClientAreaScreenBounds() const OVERRIDE; |
| virtual void SetBounds(const gfx::Rect& bounds) OVERRIDE; |
| @@ -292,6 +297,9 @@ class WidgetGtk : public Widget, |
| // Overridden from NativeWidget |
| virtual gfx::AcceleratedWidget GetAcceleratedWidget() OVERRIDE; |
| + // Overridden from internal::InputMethodDelegate |
| + virtual void DispatchKeyEventPostIME(const KeyEvent& key) OVERRIDE; |
| + |
| CHROMEGTK_CALLBACK_1(WidgetGtk, gboolean, OnWindowPaint, GdkEventExpose*); |
| // Process a mouse click. |
| @@ -425,6 +433,8 @@ class WidgetGtk : public Widget, |
| // view the drag started from. |
| View* dragged_view_; |
| + scoped_ptr<InputMethod> input_method_; |
|
sadrul
2011/03/21 19:57:45
Would it be possible to move input_method_ to Widg
James Su
2011/03/21 21:34:07
IMHO, it's not possible, different input method im
|
| + |
| DISALLOW_COPY_AND_ASSIGN(WidgetGtk); |
| }; |