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

Unified Diff: mojo/services/public/cpp/view_manager/lib/view.cc

Issue 728553002: Update mojo sdk to rev afb4440fd5a10cba980878c326180b7ad7960480 (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 1 month 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: mojo/services/public/cpp/view_manager/lib/view.cc
diff --git a/mojo/services/public/cpp/view_manager/lib/view.cc b/mojo/services/public/cpp/view_manager/lib/view.cc
index 84a0455a9dfeab31aae0d1b27483a9ae21fb7e58..b371000ee798c25e46bd83667c09743b52a1dec6 100644
--- a/mojo/services/public/cpp/view_manager/lib/view.cc
+++ b/mojo/services/public/cpp/view_manager/lib/view.cc
@@ -311,6 +311,10 @@ void View::Reorder(View* relative, OrderDirection direction) {
}
bool View::Contains(View* child) const {
+ if (!child)
+ return false;
+ if (child == this)
+ return true;
if (manager_)
CHECK_EQ(ViewPrivate(child).view_manager(), manager_);
for (View* p = child->parent(); p; p = p->parent()) {

Powered by Google App Engine
This is Rietveld 408576698