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

Side by Side Diff: ui/keyboard/keyboard_util.h

Issue 2444443002: cros: Allow pin keyboard to keep focus without popping up the pin keyboard. (Closed)
Patch Set: Fixed patch set 8 errors. Created 4 years, 1 month 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 (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 // TODO(beng): replace with forward decl once RootWindow is renamed. 10 // TODO(beng): replace with forward decl once RootWindow is renamed.
(...skipping 47 matching lines...) Expand 10 before | Expand all | Expand 10 after
58 // Request virtual keyboard be suppressed. 58 // Request virtual keyboard be suppressed.
59 KEYBOARD_STATE_DISABLED, 59 KEYBOARD_STATE_DISABLED,
60 }; 60 };
61 61
62 // Gets the calculated keyboard bounds from |root_bounds|. The keyboard height 62 // Gets the calculated keyboard bounds from |root_bounds|. The keyboard height
63 // is specified by |keyboard_height|. This should be only called when keyboard 63 // is specified by |keyboard_height|. This should be only called when keyboard
64 // is in FULL_WDITH mode. 64 // is in FULL_WDITH mode.
65 KEYBOARD_EXPORT gfx::Rect FullWidthKeyboardBoundsFromRootBounds( 65 KEYBOARD_EXPORT gfx::Rect FullWidthKeyboardBoundsFromRootBounds(
66 const gfx::Rect& root_bounds, int keyboard_height); 66 const gfx::Rect& root_bounds, int keyboard_height);
67 67
68 // Blocks the keyboard from showing up. This should only be used for cases where
69 // the focus needs to be passed around without poping up the keyboard. It needs
70 // to be turned off when done with otherwise the keyboard will not pop up again.
71 KEYBOARD_EXPORT void SetForceDisableVirtualKeyboardForWebUi(bool disable);
72
73 // Return true if keyboard has been blocked from showing up for web ui purposes.
74 KEYBOARD_EXPORT bool GetForceDisableVirtualKeyboardForWebUi();
75
68 // Sets the state of the a11y onscreen keyboard. 76 // Sets the state of the a11y onscreen keyboard.
69 KEYBOARD_EXPORT void SetAccessibilityKeyboardEnabled(bool enabled); 77 KEYBOARD_EXPORT void SetAccessibilityKeyboardEnabled(bool enabled);
70 78
71 // Gets the state of the a11y onscreen keyboard. 79 // Gets the state of the a11y onscreen keyboard.
72 KEYBOARD_EXPORT bool GetAccessibilityKeyboardEnabled(); 80 KEYBOARD_EXPORT bool GetAccessibilityKeyboardEnabled();
73 81
74 // Sets the state of the hotrod onscreen keyboard. 82 // Sets the state of the hotrod onscreen keyboard.
75 KEYBOARD_EXPORT void SetHotrodKeyboardEnabled(bool enabled); 83 KEYBOARD_EXPORT void SetHotrodKeyboardEnabled(bool enabled);
76 84
77 // Gets the state of the hotrod onscreen keyboard. 85 // Gets the state of the hotrod onscreen keyboard.
(...skipping 87 matching lines...) Expand 10 before | Expand all | Expand 10 after
165 173
166 // Gets the override content url. 174 // Gets the override content url.
167 KEYBOARD_EXPORT const GURL& GetOverrideContentUrl(); 175 KEYBOARD_EXPORT const GURL& GetOverrideContentUrl();
168 176
169 // Logs the keyboard control event as a UMA stat. 177 // Logs the keyboard control event as a UMA stat.
170 void LogKeyboardControlEvent(KeyboardControlEvent event); 178 void LogKeyboardControlEvent(KeyboardControlEvent event);
171 179
172 } // namespace keyboard 180 } // namespace keyboard
173 181
174 #endif // UI_KEYBOARD_KEYBOARD_UTIL_H_ 182 #endif // UI_KEYBOARD_KEYBOARD_UTIL_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698