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

Side by Side Diff: chrome/browser/extensions/api/virtual_keyboard_private/chrome_virtual_keyboard_delegate.cc

Issue 848843003: Add a --enable-gesture-typing flag. Currently this flag does nothing. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: add histogram enume ntry Created 5 years, 11 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 #include "chrome/browser/extensions/api/virtual_keyboard_private/chrome_virtual_ keyboard_delegate.h" 5 #include "chrome/browser/extensions/api/virtual_keyboard_private/chrome_virtual_ keyboard_delegate.h"
6 6
7 #include "base/command_line.h" 7 #include "base/command_line.h"
8 #include "base/metrics/histogram.h" 8 #include "base/metrics/histogram.h"
9 #include "base/metrics/user_metrics_action.h" 9 #include "base/metrics/user_metrics_action.h"
10 #include "base/strings/string16.h" 10 #include "base/strings/string16.h"
(...skipping 21 matching lines...) Expand all
32 32
33 namespace extensions { 33 namespace extensions {
34 34
35 bool ChromeVirtualKeyboardDelegate::GetKeyboardConfig( 35 bool ChromeVirtualKeyboardDelegate::GetKeyboardConfig(
36 base::DictionaryValue* results) { 36 base::DictionaryValue* results) {
37 DCHECK_CURRENTLY_ON(content::BrowserThread::UI); 37 DCHECK_CURRENTLY_ON(content::BrowserThread::UI);
38 results->SetString("layout", keyboard::GetKeyboardLayout()); 38 results->SetString("layout", keyboard::GetKeyboardLayout());
39 results->SetBoolean("a11ymode", keyboard::GetAccessibilityKeyboardEnabled()); 39 results->SetBoolean("a11ymode", keyboard::GetAccessibilityKeyboardEnabled());
40 results->SetBoolean("experimental", 40 results->SetBoolean("experimental",
41 keyboard::IsExperimentalInputViewEnabled()); 41 keyboard::IsExperimentalInputViewEnabled());
42 results->SetBoolean("gesturetyping", keyboard::IsGestureTypingEnabled());
42 return true; 43 return true;
43 } 44 }
44 45
45 bool ChromeVirtualKeyboardDelegate::HideKeyboard() { 46 bool ChromeVirtualKeyboardDelegate::HideKeyboard() {
46 DCHECK_CURRENTLY_ON(content::BrowserThread::UI); 47 DCHECK_CURRENTLY_ON(content::BrowserThread::UI);
47 keyboard::KeyboardController* controller = 48 keyboard::KeyboardController* controller =
48 keyboard::KeyboardController::GetInstance(); 49 keyboard::KeyboardController::GetInstance();
49 if (!controller) 50 if (!controller)
50 return false; 51 return false;
51 52
(...skipping 66 matching lines...) Expand 10 before | Expand all | Expand 10 after
118 } 119 }
119 120
120 bool ChromeVirtualKeyboardDelegate::IsLanguageSettingsEnabled() { 121 bool ChromeVirtualKeyboardDelegate::IsLanguageSettingsEnabled() {
121 return (user_manager::UserManager::Get()->IsUserLoggedIn() && 122 return (user_manager::UserManager::Get()->IsUserLoggedIn() &&
122 !chromeos::UserAddingScreen::Get()->IsRunning() && 123 !chromeos::UserAddingScreen::Get()->IsRunning() &&
123 !(chromeos::ScreenLocker::default_screen_locker() && 124 !(chromeos::ScreenLocker::default_screen_locker() &&
124 chromeos::ScreenLocker::default_screen_locker()->locked())); 125 chromeos::ScreenLocker::default_screen_locker()->locked()));
125 } 126 }
126 127
127 } // namespace extensions 128 } // namespace extensions
OLDNEW
« no previous file with comments | « chrome/browser/about_flags.cc ('k') | chrome/test/data/chromeos/virtual_keyboard/virtual_keyboard_test_base.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698