| OLD | NEW |
| 1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2013 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_KEYBOARD_KEYBOARD_UTIL_H_ | 5 #ifndef UI_KEYBOARD_KEYBOARD_UTIL_H_ |
| 6 #define UI_KEYBOARD_KEYBOARD_UTIL_H_ | 6 #define UI_KEYBOARD_KEYBOARD_UTIL_H_ |
| 7 | 7 |
| 8 #include <string> | 8 #include <string> |
| 9 | 9 |
| 10 #include "base/strings/string16.h" | 10 #include "base/strings/string16.h" |
| (...skipping 78 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 89 // Sets policy override on whether to show the keyboard. | 89 // Sets policy override on whether to show the keyboard. |
| 90 KEYBOARD_EXPORT void SetKeyboardShowOverride(KeyboardShowOverride override); | 90 KEYBOARD_EXPORT void SetKeyboardShowOverride(KeyboardShowOverride override); |
| 91 | 91 |
| 92 // Returns true if an IME extension can specify a custom input view for the | 92 // Returns true if an IME extension can specify a custom input view for the |
| 93 // virtual keyboard window. | 93 // virtual keyboard window. |
| 94 KEYBOARD_EXPORT bool IsInputViewEnabled(); | 94 KEYBOARD_EXPORT bool IsInputViewEnabled(); |
| 95 | 95 |
| 96 // Returns true if experimental features are enabled for IME input-views. | 96 // Returns true if experimental features are enabled for IME input-views. |
| 97 KEYBOARD_EXPORT bool IsExperimentalInputViewEnabled(); | 97 KEYBOARD_EXPORT bool IsExperimentalInputViewEnabled(); |
| 98 | 98 |
| 99 // Returns true if gesture typing is enabled for virtual keyboard. |
| 100 KEYBOARD_EXPORT bool IsGestureTypingEnabled(); |
| 101 |
| 99 // Insert |text| into the active TextInputClient if there is one. Returns true | 102 // Insert |text| into the active TextInputClient if there is one. Returns true |
| 100 // if |text| was successfully inserted. | 103 // if |text| was successfully inserted. |
| 101 KEYBOARD_EXPORT bool InsertText(const base::string16& text); | 104 KEYBOARD_EXPORT bool InsertText(const base::string16& text); |
| 102 | 105 |
| 103 // Move cursor when swipe on the virtualkeyboard. Returns true if cursor was | 106 // Move cursor when swipe on the virtualkeyboard. Returns true if cursor was |
| 104 // successfully moved according to |swipe_direction|. | 107 // successfully moved according to |swipe_direction|. |
| 105 KEYBOARD_EXPORT bool MoveCursor(int swipe_direction, | 108 KEYBOARD_EXPORT bool MoveCursor(int swipe_direction, |
| 106 int modifier_flags, | 109 int modifier_flags, |
| 107 aura::WindowTreeHost* host); | 110 aura::WindowTreeHost* host); |
| 108 | 111 |
| (...skipping 30 matching lines...) Expand all Loading... |
| 139 | 142 |
| 140 // Gets the override content url. | 143 // Gets the override content url. |
| 141 KEYBOARD_EXPORT const GURL& GetOverrideContentUrl(); | 144 KEYBOARD_EXPORT const GURL& GetOverrideContentUrl(); |
| 142 | 145 |
| 143 // Logs the keyboard control event as a UMA stat. | 146 // Logs the keyboard control event as a UMA stat. |
| 144 void LogKeyboardControlEvent(KeyboardControlEvent event); | 147 void LogKeyboardControlEvent(KeyboardControlEvent event); |
| 145 | 148 |
| 146 } // namespace keyboard | 149 } // namespace keyboard |
| 147 | 150 |
| 148 #endif // UI_KEYBOARD_KEYBOARD_UTIL_H_ | 151 #endif // UI_KEYBOARD_KEYBOARD_UTIL_H_ |
| OLD | NEW |