| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 UI_BASE_IME_INPUT_METHOD_H_ | 5 #ifndef UI_BASE_IME_INPUT_METHOD_H_ |
| 6 #define UI_BASE_IME_INPUT_METHOD_H_ | 6 #define UI_BASE_IME_INPUT_METHOD_H_ |
| 7 | 7 |
| 8 #include <string> | 8 #include <string> |
| 9 | 9 |
| 10 #include "base/basictypes.h" | 10 #include "base/basictypes.h" |
| 11 #include "base/event_types.h" | 11 #include "base/event_types.h" |
| 12 #include "base/i18n/rtl.h" | 12 #include "base/i18n/rtl.h" |
| 13 #include "ui/base/ime/text_input_mode.h" |
| 13 #include "ui/base/ime/text_input_type.h" | 14 #include "ui/base/ime/text_input_type.h" |
| 14 #include "ui/base/keycodes/keyboard_codes.h" | 15 #include "ui/base/keycodes/keyboard_codes.h" |
| 15 #include "ui/base/ui_export.h" | 16 #include "ui/base/ui_export.h" |
| 16 | 17 |
| 17 namespace ui { | 18 namespace ui { |
| 18 | 19 |
| 19 namespace internal { | 20 namespace internal { |
| 20 class InputMethodDelegate; | 21 class InputMethodDelegate; |
| 21 } // namespace internal | 22 } // namespace internal |
| 22 | 23 |
| (...skipping 114 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 137 // changes of caret bounds and text input type. | 138 // changes of caret bounds and text input type. |
| 138 // Note: character results may still be generated and sent to the text input | 139 // Note: character results may still be generated and sent to the text input |
| 139 // client by calling TextInputClient::InsertChar(), even if the input method | 140 // client by calling TextInputClient::InsertChar(), even if the input method |
| 140 // is not active. | 141 // is not active. |
| 141 virtual bool IsActive() = 0; | 142 virtual bool IsActive() = 0; |
| 142 | 143 |
| 143 // Gets the text input type of the focused text input client. Returns | 144 // Gets the text input type of the focused text input client. Returns |
| 144 // ui::TEXT_INPUT_TYPE_NONE if there is no focused client. | 145 // ui::TEXT_INPUT_TYPE_NONE if there is no focused client. |
| 145 virtual TextInputType GetTextInputType() const = 0; | 146 virtual TextInputType GetTextInputType() const = 0; |
| 146 | 147 |
| 148 // Gets the text input mode of the focused text input client. Returns |
| 149 // ui::TEXT_INPUT_TYPE_DEFAULT if there is no focused client. |
| 150 virtual TextInputMode GetTextInputMode() const = 0; |
| 151 |
| 147 // Checks if the focused text input client supports inline composition. | 152 // Checks if the focused text input client supports inline composition. |
| 148 virtual bool CanComposeInline() const = 0; | 153 virtual bool CanComposeInline() const = 0; |
| 149 | 154 |
| 150 // Returns true if we know for sure that a candidate window (or IME suggest, | 155 // Returns true if we know for sure that a candidate window (or IME suggest, |
| 151 // etc.) is open. Returns false if no popup window is open or the detection | 156 // etc.) is open. Returns false if no popup window is open or the detection |
| 152 // of IME popups is not supported. | 157 // of IME popups is not supported. |
| 153 virtual bool IsCandidatePopupOpen() const = 0; | 158 virtual bool IsCandidatePopupOpen() const = 0; |
| 154 | 159 |
| 155 // Management of the observer list. | 160 // Management of the observer list. |
| 156 virtual void AddObserver(InputMethodObserver* observer) = 0; | 161 virtual void AddObserver(InputMethodObserver* observer) = 0; |
| 157 virtual void RemoveObserver(InputMethodObserver* observer) = 0; | 162 virtual void RemoveObserver(InputMethodObserver* observer) = 0; |
| 158 }; | 163 }; |
| 159 | 164 |
| 160 } // namespace ui | 165 } // namespace ui |
| 161 | 166 |
| 162 #endif // UI_BASE_IME_INPUT_METHOD_H_ | 167 #endif // UI_BASE_IME_INPUT_METHOD_H_ |
| OLD | NEW |