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

Unified Diff: ui/aura/window_port.h

Issue 2632543003: Refactor and push window properties up to class properties. (Closed)
Patch Set: Created 3 years, 11 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: ui/aura/window_port.h
diff --git a/ui/aura/window_port.h b/ui/aura/window_port.h
index b82305d2206d07bb9c13d90de7e01b41552fede0..b1843560c73a01aace54417b30acc7ae13c5c9ca 100644
--- a/ui/aura/window_port.h
+++ b/ui/aura/window_port.h
@@ -13,6 +13,7 @@
#include "base/observer_list.h"
#include "base/strings/string16.h"
#include "ui/aura/aura_export.h"
+#include "ui/base/class_property.h"
namespace gfx {
class Rect;
@@ -24,9 +25,10 @@ class Window;
class WindowObserver;
// See comments in OnWillChangeProperty() for details.
-struct AURA_EXPORT WindowPortPropertyData {
- virtual ~WindowPortPropertyData() {}
-};
+//using WindowPortPropertyData = ui::PropertyData;
+//struct AURA_EXPORT WindowPortPropertyData : public ui::PropertyData {
+// ~WindowPortPropertyData() override {}
+//};
// WindowPort defines an interface to enable Window to be used with or without
// mus. WindowPort is owned by Window and called at key points in Windows
@@ -65,14 +67,14 @@ class AURA_EXPORT WindowPort {
// Called before a property is changed. The return value from this is supplied
// into OnPropertyChanged() so that WindowPort may pass data between the two
// calls.
- virtual std::unique_ptr<WindowPortPropertyData> OnWillChangeProperty(
+ virtual std::unique_ptr<ui::PropertyData> OnWillChangeProperty(
const void* key) = 0;
// Called after a property changes, but before observers are notified. |data|
// is the return value from OnWillChangeProperty().
virtual void OnPropertyChanged(
const void* key,
- std::unique_ptr<WindowPortPropertyData> data) = 0;
+ std::unique_ptr<ui::PropertyData> data) = 0;
protected:
// Returns the WindowPort associated with a Window.

Powered by Google App Engine
This is Rietveld 408576698