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

Unified Diff: components/exo/pointer.h

Issue 2071553002: Initial support of large mouse cursor on Exosphere (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: for comment #13 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
Index: components/exo/pointer.h
diff --git a/components/exo/pointer.h b/components/exo/pointer.h
index d063a7ba92bb089920d2874252981e49c88ed59e..f3ccd6280ac4467d8950fcaa2da74cabbe3039b6 100644
--- a/components/exo/pointer.h
+++ b/components/exo/pointer.h
@@ -10,6 +10,7 @@
#include "base/macros.h"
#include "components/exo/surface_delegate.h"
#include "components/exo/surface_observer.h"
+#include "ui/aura/client/cursor_client_observer.h"
#include "ui/events/event_handler.h"
#include "ui/gfx/geometry/point.h"
#include "ui/gfx/geometry/point_f.h"
@@ -31,6 +32,7 @@ class Surface;
// This class implements a client pointer that represents one or more input
// devices, such as mice, which control the pointer location and pointer focus.
class Pointer : public ui::EventHandler,
+ public aura::client::CursorClientObserver,
public SurfaceDelegate,
public SurfaceObserver {
public:
@@ -48,6 +50,9 @@ class Pointer : public ui::EventHandler,
void OnMouseEvent(ui::MouseEvent* event) override;
void OnScrollEvent(ui::ScrollEvent* event) override;
+ // Overridden from aura::client::CursorClientObserver:
+ void OnCursorSetChanged(ui::CursorSetType cursor_set) override;
+
// Overridden from SurfaceDelegate:
void OnSurfaceCommit() override;
bool IsSurfaceSynchronized() const override;
@@ -59,6 +64,9 @@ class Pointer : public ui::EventHandler,
// Creates the |widget_| for pointer.
void CreatePointerWidget();
+ // Updates the scale of the cursor with the latest state.
+ void UpdateCursorScale();
+
// Returns the effective target for |event|.
Surface* GetEffectiveTargetForEvent(ui::Event* event) const;

Powered by Google App Engine
This is Rietveld 408576698