| OLD | NEW |
| 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #ifndef CHROME_BROWSER_RENDERER_HOST_GTK_IM_CONTEXT_WRAPPER_H_ | 5 #ifndef CHROME_BROWSER_RENDERER_HOST_GTK_IM_CONTEXT_WRAPPER_H_ |
| 6 #define CHROME_BROWSER_RENDERER_HOST_GTK_IM_CONTEXT_WRAPPER_H_ | 6 #define CHROME_BROWSER_RENDERER_HOST_GTK_IM_CONTEXT_WRAPPER_H_ |
| 7 #pragma once | 7 #pragma once |
| 8 | 8 |
| 9 #include <gdk/gdk.h> | 9 #include <gdk/gdk.h> |
| 10 #include <pango/pango-attributes.h> | 10 #include <pango/pango-attributes.h> |
| (...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 46 ~GtkIMContextWrapper(); | 46 ~GtkIMContextWrapper(); |
| 47 | 47 |
| 48 // Processes a gdk key event received by |host_view|. | 48 // Processes a gdk key event received by |host_view|. |
| 49 void ProcessKeyEvent(GdkEventKey* event); | 49 void ProcessKeyEvent(GdkEventKey* event); |
| 50 | 50 |
| 51 void UpdateInputMethodState(ui::TextInputType type, | 51 void UpdateInputMethodState(ui::TextInputType type, |
| 52 bool can_compose_inline, | 52 bool can_compose_inline, |
| 53 const gfx::Rect& caret_rect); | 53 const gfx::Rect& caret_rect); |
| 54 void OnFocusIn(); | 54 void OnFocusIn(); |
| 55 void OnFocusOut(); | 55 void OnFocusOut(); |
| 56 bool is_focused() const { return is_focused_; } |
| 56 | 57 |
| 57 #if !defined(TOOLKIT_VIEWS) | 58 #if !defined(TOOLKIT_VIEWS) |
| 58 // Not defined for views because the views context menu doesn't | 59 // Not defined for views because the views context menu doesn't |
| 59 // implement input methods yet. | 60 // implement input methods yet. |
| 60 void AppendInputMethodsContextMenu(MenuGtk* menu); | 61 void AppendInputMethodsContextMenu(MenuGtk* menu); |
| 61 #endif | 62 #endif |
| 62 | 63 |
| 63 void CancelComposition(); | 64 void CancelComposition(); |
| 64 | 65 |
| 65 void ConfirmComposition(); | 66 void ConfirmComposition(); |
| (...skipping 124 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 190 // Information of the last key event, for working around | 191 // Information of the last key event, for working around |
| 191 // http://crosbug.com/6582 | 192 // http://crosbug.com/6582 |
| 192 int last_key_code_; | 193 int last_key_code_; |
| 193 bool last_key_was_up_; | 194 bool last_key_was_up_; |
| 194 bool last_key_filtered_no_result_; | 195 bool last_key_filtered_no_result_; |
| 195 | 196 |
| 196 DISALLOW_COPY_AND_ASSIGN(GtkIMContextWrapper); | 197 DISALLOW_COPY_AND_ASSIGN(GtkIMContextWrapper); |
| 197 }; | 198 }; |
| 198 | 199 |
| 199 #endif // CHROME_BROWSER_RENDERER_HOST_GTK_IM_CONTEXT_WRAPPER_H_ | 200 #endif // CHROME_BROWSER_RENDERER_HOST_GTK_IM_CONTEXT_WRAPPER_H_ |
| OLD | NEW |