Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(365)

Side by Side Diff: extensions/browser/api/virtual_keyboard_private/virtual_keyboard_delegate.h

Issue 1339763004: Add chrome.virtualKeyboardPrivate.setHotrodKeyboard api (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@2490
Patch Set: Created 5 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 EXTENSIONS_BROWSER_API_VIRTUAL_KEYBOARD_VIRTUAL_KEYBOARD_DELEGATE_H_ 5 #ifndef EXTENSIONS_BROWSER_API_VIRTUAL_KEYBOARD_VIRTUAL_KEYBOARD_DELEGATE_H_
6 #define EXTENSIONS_BROWSER_API_VIRTUAL_KEYBOARD_VIRTUAL_KEYBOARD_DELEGATE_H_ 6 #define EXTENSIONS_BROWSER_API_VIRTUAL_KEYBOARD_VIRTUAL_KEYBOARD_DELEGATE_H_
7 7
8 #include "base/macros.h" 8 #include "base/macros.h"
9 #include "base/strings/string16.h" 9 #include "base/strings/string16.h"
10 #include "base/values.h" 10 #include "base/values.h"
(...skipping 18 matching lines...) Expand all
29 virtual bool InsertText(const base::string16& text) = 0; 29 virtual bool InsertText(const base::string16& text) = 0;
30 30
31 // Notifiy system that keyboard loading is complete. Used in UMA stats to 31 // Notifiy system that keyboard loading is complete. Used in UMA stats to
32 // track loading performance. Returns true if the notification was handled. 32 // track loading performance. Returns true if the notification was handled.
33 virtual bool OnKeyboardLoaded() = 0; 33 virtual bool OnKeyboardLoaded() = 0;
34 34
35 // Indicate if settings are accessible and enabled based on current state. 35 // Indicate if settings are accessible and enabled based on current state.
36 // For example, settings should be blocked when the session is locked. 36 // For example, settings should be blocked when the session is locked.
37 virtual bool IsLanguageSettingsEnabled() = 0; 37 virtual bool IsLanguageSettingsEnabled() = 0;
38 38
39 // Sets the state of the hotrod virtual keyboad.
40 virtual void SetHotrodKeyboard(bool enable) = 0;
41
39 // Activate and lock the virtual keyboad on screen or dismiss the keyboard 42 // Activate and lock the virtual keyboad on screen or dismiss the keyboard
40 // regardless of the state of text focus. Used in a11y mode to allow typing 43 // regardless of the state of text focus. Used in a11y mode to allow typing
41 // hotkeys without the need for text focus. Returns true if successful. 44 // hotkeys without the need for text focus. Returns true if successful.
42 virtual bool LockKeyboard(bool state) = 0; 45 virtual bool LockKeyboard(bool state) = 0;
43 46
44 // Dispatches a virtual key event. |type| indicates if the event is a keydown 47 // Dispatches a virtual key event. |type| indicates if the event is a keydown
45 // or keyup event. |char_value| is the unicode value for the key. |key_code| 48 // or keyup event. |char_value| is the unicode value for the key. |key_code|
46 // is the code assigned to the key, which is independent of the state of 49 // is the code assigned to the key, which is independent of the state of
47 // modifier keys. |key_name| is the standardized w3c name for the key. 50 // modifier keys. |key_name| is the standardized w3c name for the key.
48 // |modifiers| indicates which modifier keys are active. Returns true if 51 // |modifiers| indicates which modifier keys are active. Returns true if
(...skipping 10 matching lines...) Expand all
59 // Sets virtual keyboard window mode. 62 // Sets virtual keyboard window mode.
60 virtual bool SetVirtualKeyboardMode(int mode_enum) = 0; 63 virtual bool SetVirtualKeyboardMode(int mode_enum) = 0;
61 64
62 // Sets requested virtual keyboard state. 65 // Sets requested virtual keyboard state.
63 virtual bool SetRequestedKeyboardState(int state_enum) = 0; 66 virtual bool SetRequestedKeyboardState(int state_enum) = 0;
64 }; 67 };
65 68
66 } // namespace extensions 69 } // namespace extensions
67 70
68 #endif // EXTENSIONS_BROWSER_API_VIRTUAL_KEYBOARD_VIRTUAL_KEYBOARD_DELEGATE_H_ 71 #endif // EXTENSIONS_BROWSER_API_VIRTUAL_KEYBOARD_VIRTUAL_KEYBOARD_DELEGATE_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698