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

Unified Diff: components/mus/public/cpp/window.h

Issue 1465803003: mus: Let clients set the cursor of their window. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Do it the other way + explicit checks that it is a mouse pointer. Created 5 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/mus/public/cpp/tests/test_window_tree.cc ('k') | components/mus/public/cpp/window_observer.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: components/mus/public/cpp/window.h
diff --git a/components/mus/public/cpp/window.h b/components/mus/public/cpp/window.h
index 9da43ce6f31e9c5d07e5cb7dde6f8d78401be0c0..668b703cbff468fe49546a91b7333101bb1e1c7b 100644
--- a/components/mus/public/cpp/window.h
+++ b/components/mus/public/cpp/window.h
@@ -78,6 +78,10 @@ class Window {
bool visible() const { return visible_; }
void SetVisible(bool value);
+ // Cursors
+ mojom::Cursor predefined_cursor() const { return cursor_id_; }
+ void SetPredefinedCursor(mus::mojom::Cursor cursor_id);
+
// A Window is drawn if the Window and all its ancestors are visible and the
// Window is attached to the root.
bool IsDrawn() const;
@@ -224,6 +228,7 @@ class Window {
const mojom::ViewportMetrics& new_metrics);
void LocalSetDrawn(bool drawn);
void LocalSetVisible(bool visible);
+ void LocalSetPredefinedCursor(mojom::Cursor cursor_id);
void LocalSetSharedProperty(const std::string& name,
const std::vector<uint8_t>* data);
@@ -276,6 +281,8 @@ class Window {
bool visible_;
+ mojom::Cursor cursor_id_;
+
SharedProperties properties_;
// Drawn state is derived from the visible state and the parent's visible
« no previous file with comments | « components/mus/public/cpp/tests/test_window_tree.cc ('k') | components/mus/public/cpp/window_observer.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698