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

Unified Diff: components/mus/public/cpp/lib/in_flight_change.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: Fix WindowTreeAppTest.SetCursor. 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
Index: components/mus/public/cpp/lib/in_flight_change.h
diff --git a/components/mus/public/cpp/lib/in_flight_change.h b/components/mus/public/cpp/lib/in_flight_change.h
index 3dc42a74724165afbdbd76d65714df26ad8c59b9..4231251e18de3e326eb3c437aae223955c861799 100644
--- a/components/mus/public/cpp/lib/in_flight_change.h
+++ b/components/mus/public/cpp/lib/in_flight_change.h
@@ -15,6 +15,10 @@
namespace mus {
+namespace mojom {
+enum Cursor : int32_t;
+}
+
class Window;
enum class ChangeType {
@@ -23,7 +27,8 @@ enum class ChangeType {
DELETE_WINDOW,
NEW_WINDOW,
PROPERTY,
- REMOVE_TRANSIENT_WINDOW_FROM_PARENT
+ REMOVE_TRANSIENT_WINDOW_FROM_PARENT,
+ PREDEFINED_CURSOR
sky 2015/12/02 21:42:35 nit: keep sorted.
};
// InFlightChange is used to track function calls to the server and take the
@@ -130,6 +135,22 @@ class InFlightPropertyChange : public InFlightChange {
DISALLOW_COPY_AND_ASSIGN(InFlightPropertyChange);
};
+class InFlightPredefinedCursorChange : public InFlightChange {
+ public:
+ InFlightPredefinedCursorChange(Window* window, mojom::Cursor revert_value);
+ ~InFlightPredefinedCursorChange() override;
+
+ // InFlightChange:
+ bool Matches(const InFlightChange& change) const override;
+ void SetRevertValueFrom(const InFlightChange& change) override;
+ void Revert() override;
+
+ private:
+ mojom::Cursor revert_cursor_;
+
+ DISALLOW_COPY_AND_ASSIGN(InFlightPredefinedCursorChange);
+};
+
} // namespace mus
#endif // COMPONENTS_MUS_PUBLIC_CPP_LIB_IN_FLIGHT_CHANGE_H_
« no previous file with comments | « no previous file | components/mus/public/cpp/lib/in_flight_change.cc » ('j') | components/mus/public/cpp/lib/in_flight_change.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698