Index: ui/events/devices/device_data_manager.h |
diff --git a/ui/events/devices/device_data_manager.h b/ui/events/devices/device_data_manager.h |
index d8ede81f22d885982daf0997bcbba8d56b94df00..f3782ebd02629af8341bc470a5341dc72ec5a5a6 100644 |
--- a/ui/events/devices/device_data_manager.h |
+++ b/ui/events/devices/device_data_manager.h |
@@ -20,6 +20,10 @@ |
namespace ui { |
+namespace test { |
+class DeviceDataManagerTestAPI; |
+} // namespace test |
+ |
class InputDeviceEventObserver; |
// Keeps track of device mappings and event transformations. |
@@ -30,6 +34,7 @@ class EVENTS_DEVICES_EXPORT DeviceDataManager |
~DeviceDataManager() override; |
static void CreateInstance(); |
+ static void DeleteInstance(); |
static DeviceDataManager* GetInstance(); |
static bool HasInstance(); |
@@ -63,6 +68,8 @@ class EVENTS_DEVICES_EXPORT DeviceDataManager |
static DeviceDataManager* instance(); |
+ static void set_instance(DeviceDataManager* instance); |
+ |
// DeviceHotplugEventObserver: |
void OnTouchscreenDevicesUpdated( |
const std::vector<TouchscreenDevice>& devices) override; |
@@ -75,10 +82,18 @@ class EVENTS_DEVICES_EXPORT DeviceDataManager |
void OnDeviceListsComplete() override; |
private: |
+ friend class test::DeviceDataManagerTestAPI; |
+ |
static DeviceDataManager* instance_; |
bool IsTouchDeviceIdValid(int touch_device_id) const; |
+ void NotifyObserversTouchscreenDeviceConfigurationChanged(); |
+ void NotifyObserversKeyboardDeviceConfigurationChanged(); |
+ void NotifyObserversMouseDeviceConfigurationChanged(); |
+ void NotifyObserversTouchpadDeviceConfigurationChanged(); |
+ void NotifyObserversDeviceListsComplete(); |
+ |
double touch_radius_scale_map_[kMaxDeviceNum]; |
// Index table to find the target display id for a touch device. |