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

Unified Diff: ui/base/touch/touch_device_linux.cc

Issue 2028593004: Add new InputDeviceManager interface. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@remove_keyboard
Patch Set: Fix windows compile error. Created 4 years, 7 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « ui/base/material_design/material_design_controller.cc ('k') | ui/events/devices/BUILD.gn » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/base/touch/touch_device_linux.cc
diff --git a/ui/base/touch/touch_device_linux.cc b/ui/base/touch/touch_device_linux.cc
index 0bc89706c184b85fb0785801e0f8b460ba4085c8..5767fb82ac5823776343abbbb62a1501d1d4b6d8 100644
--- a/ui/base/touch/touch_device_linux.cc
+++ b/ui/base/touch/touch_device_linux.cc
@@ -5,14 +5,14 @@
#include "ui/base/touch/touch_device.h"
#include "base/logging.h"
-#include "ui/events/devices/device_data_manager.h"
+#include "ui/events/devices/input_device_manager.h"
namespace ui {
namespace {
bool IsTouchDevicePresent() {
- return !DeviceDataManager::GetInstance()->touchscreen_devices().empty();
+ return !InputDeviceManager::GetInstance()->GetTouchscreenDevices().empty();
}
} // namespace
@@ -21,15 +21,15 @@ TouchScreensAvailability GetTouchScreensAvailability() {
if (!IsTouchDevicePresent())
return TouchScreensAvailability::NONE;
- return DeviceDataManager::GetInstance()->AreTouchscreensEnabled() ?
- TouchScreensAvailability::ENABLED :
- TouchScreensAvailability::DISABLED;
+ return InputDeviceManager::GetInstance()->AreTouchscreensEnabled()
+ ? TouchScreensAvailability::ENABLED
+ : TouchScreensAvailability::DISABLED;
}
int MaxTouchPoints() {
int max_touch = 0;
const std::vector<ui::TouchscreenDevice>& touchscreen_devices =
- ui::DeviceDataManager::GetInstance()->touchscreen_devices();
+ ui::InputDeviceManager::GetInstance()->GetTouchscreenDevices();
for (const ui::TouchscreenDevice& device : touchscreen_devices) {
if (device.touch_points > max_touch)
max_touch = device.touch_points;
« no previous file with comments | « ui/base/material_design/material_design_controller.cc ('k') | ui/events/devices/BUILD.gn » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698