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

Unified Diff: chrome/browser/chromeos/system/input_device_settings.h

Issue 1412623006: Developer Feature: Add Debug Accelerators to Toggle Touchscreen/Touchpad On or Off (CrOS) (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: sadrul's comment Created 5 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/chromeos/system/input_device_settings.h
diff --git a/chrome/browser/chromeos/system/input_device_settings.h b/chrome/browser/chromeos/system/input_device_settings.h
index 5807e9d7b922ea78facba52f27d021645021e9a1..99fa69c4f8539b2054e29010dbe6b9224bea4756 100644
--- a/chrome/browser/chromeos/system/input_device_settings.h
+++ b/chrome/browser/chromeos/system/input_device_settings.h
@@ -9,6 +9,8 @@
#include "base/logging.h"
#include "chromeos/chromeos_export.h"
+class PrefRegistrySimple;
+
namespace chromeos {
namespace system {
@@ -165,6 +167,16 @@ class CHROMEOS_EXPORT InputDeviceSettings {
// where other input devices like mouse are absent.
static bool ForceKeyboardDrivenUINavigation();
+ // Registers local pref names for touchpad and touch screen statuses.
+ static void RegisterPrefs(PrefRegistrySimple* registry);
+
+ void InitTouchDevicesStatusFromLocalPrefs();
+
+ // Toggles the status of Touchscreen/Touchpad on or off and updates the local
+ // prefs.
+ void ToggleTouchscreen();
+ void ToggleTouchpad();
+
// Calls |callback| asynchronously after determining if a touchpad is
// connected.
virtual void TouchpadExists(const DeviceExistsCallback& callback) = 0;
@@ -210,6 +222,10 @@ class CHROMEOS_EXPORT InputDeviceSettings {
// Reapplies previously set mouse settings.
virtual void ReapplyMouseSettings() = 0;
+
+ private:
+ virtual void SetInternalTouchpadEnabled(bool enabled) {}
+ virtual void SetTouchscreensEnabled(bool enabled) {}
};
} // namespace system

Powered by Google App Engine
This is Rietveld 408576698