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

Unified Diff: components/exo/touch.h

Issue 2562803002: exo: Replace pointer based stylus and replace with touch based stylus (Closed)
Patch Set: updated deps in gn file Created 4 years 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/exo/test/exo_test_helper.cc ('k') | components/exo/touch.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: components/exo/touch.h
diff --git a/components/exo/touch.h b/components/exo/touch.h
index 5193f782e6787d0300d562272c353326a595aba7..63b37a8caeaa13f266851f29de423f695359d74c 100644
--- a/components/exo/touch.h
+++ b/components/exo/touch.h
@@ -10,6 +10,7 @@
#include "base/macros.h"
#include "components/exo/surface_observer.h"
#include "ui/events/event_handler.h"
+#include "ui/gfx/geometry/point_f.h"
namespace ui {
class TouchEvent;
@@ -17,6 +18,7 @@ class TouchEvent;
namespace exo {
class TouchDelegate;
+class TouchStylusDelegate;
// This class implements a client touch device that represents one or more
// touch devices.
@@ -25,6 +27,10 @@ class Touch : public ui::EventHandler, public SurfaceObserver {
explicit Touch(TouchDelegate* delegate);
~Touch() override;
+ // Set delegate for stylus events.
+ void SetStylusDelegate(TouchStylusDelegate* delegate);
+ bool HasStylusDelegate() const;
+
// Overridden from ui::EventHandler:
void OnTouchEvent(ui::TouchEvent* event) override;
@@ -38,6 +44,9 @@ class Touch : public ui::EventHandler, public SurfaceObserver {
// The delegate instance that all events are dispatched to.
TouchDelegate* const delegate_;
+ // The delegate instance that all stylus related events are dispatched to.
+ TouchStylusDelegate* stylus_delegate_ = nullptr;
+
// The current focus surface for the touch device.
Surface* focus_ = nullptr;
« no previous file with comments | « components/exo/test/exo_test_helper.cc ('k') | components/exo/touch.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698