Index: mojo/services/view_manager/public/cpp/view.h |
diff --git a/mojo/services/view_manager/public/cpp/view.h b/mojo/services/view_manager/public/cpp/view.h |
index 8569616aefb5802e963de67fd02d76887b8d5c9f..d3c62923a39956b2fed33eeda755c9ea3f7fa035 100644 |
--- a/mojo/services/view_manager/public/cpp/view.h |
+++ b/mojo/services/view_manager/public/cpp/view.h |
@@ -103,6 +103,9 @@ class View { |
View* parent() { return parent_; } |
const View* parent() const { return parent_; } |
const Children& children() const { return children_; } |
+ View* GetRoot() { |
+ return const_cast<View*>(const_cast<const View*>(this)->GetRoot()); |
+ } |
const View* GetRoot() const; |
void AddChild(View* child); |