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

Unified Diff: views/controls/native_control.cc

Issue 2883022: Re-land r51526 (Closed)
Patch Set: Created 10 years, 6 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: views/controls/native_control.cc
diff --git a/views/controls/native_control.cc b/views/controls/native_control.cc
index f7143826cc811cf16344ec38ce9eb66e63161d90..0792b29fb139b8b5b1518ea7beca75be6a6fc42c 100644
--- a/views/controls/native_control.cc
+++ b/views/controls/native_control.cc
@@ -201,7 +201,7 @@ void NativeControl::ValidateNativeControl() {
void NativeControl::ViewHierarchyChanged(bool is_add, View *parent,
View *child) {
- if (is_add && child == this && GetWidget()) {
+ if (is_add && parent != this && !container_ && GetWidget()) {
ValidateNativeControl();
Layout();
}

Powered by Google App Engine
This is Rietveld 408576698