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

Unified Diff: components/mus/ws/touch_controller.h

Issue 2081253002: Implement rudimentary touchscreen support in mus. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Add missing pure virtual. Created 4 years, 6 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 | « components/mus/ws/test_utils.cc ('k') | components/mus/ws/touch_controller.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: components/mus/ws/touch_controller.h
diff --git a/components/mus/ws/touch_controller.h b/components/mus/ws/touch_controller.h
new file mode 100644
index 0000000000000000000000000000000000000000..4505ce47164c2ad4118899328f787662514b3eb4
--- /dev/null
+++ b/components/mus/ws/touch_controller.h
@@ -0,0 +1,37 @@
+// Copyright 2016 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#ifndef COMPONENTS_MUS_WS_TOUCH_CONTROLLER_H_
+#define COMPONENTS_MUS_WS_TOUCH_CONTROLLER_H_
+
+#include "base/macros.h"
+#include "ui/events/devices/input_device_event_observer.h"
+
+namespace mus {
+namespace ws {
+
+class DisplayManager;
+
+// Tracks changes to displays and touchscreen devices. Updates the mapping
+// between display devices and touchscreen devices when changes occur.
+class TouchController : public ui::InputDeviceEventObserver {
+ public:
+ explicit TouchController(DisplayManager* display_manager);
+ ~TouchController() override;
+
+ void UpdateTouchTransforms() const;
+
+ // ui::InputDeviceEventObserver:
+ void OnTouchscreenDeviceConfigurationChanged() override;
+
+ private:
+ DisplayManager* display_manager_;
+
+ DISALLOW_COPY_AND_ASSIGN(TouchController);
+};
+
+} // namespace ws
+} // namespace mus
+
+#endif // COMPONENTS_MUS_WS_TOUCH_CONTROLLER_H_
« no previous file with comments | « components/mus/ws/test_utils.cc ('k') | components/mus/ws/touch_controller.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698