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

Unified Diff: third_party/WebKit/LayoutTests/inspector/components/widget-events.html

Issue 2168223002: DevTools: keep widgets in widget hierarchy upon hide, split attach/detach cycle from show/hide. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: lcean Created 4 years, 5 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: third_party/WebKit/LayoutTests/inspector/components/widget-events.html
diff --git a/third_party/WebKit/LayoutTests/inspector/components/widget-events.html b/third_party/WebKit/LayoutTests/inspector/components/widget-events.html
index 4174cf02cf9837471877b0dd3ebfeb50803d963b..e4cbc78c245f47dd9b3fb26a7d2e98e0f8191b54 100644
--- a/third_party/WebKit/LayoutTests/inspector/components/widget-events.html
+++ b/third_party/WebKit/LayoutTests/inspector/components/widget-events.html
@@ -151,13 +151,13 @@ function test()
var parentWidget = new TestWidget("Parent");
parentWidget.markAsRoot();
var childWidget = new TestWidget("Child");
- parentWidget.show(WebInspector.inspectorView.element);
+ parentWidget.show(document.body);
parentWidget.doResize();
childWidget.show(parentWidget.element);
parentWidget.doResize();
parentWidget.detach();
- parentWidget.show(WebInspector.inspectorView.element);
+ parentWidget.show(document.body);
childWidget.detach();
parentWidget.detach();
next();
@@ -341,6 +341,20 @@ function test()
parentWidget.show(WebInspector.inspectorView.element);
parentWidget.detach();
next();
+ },
+
+ function testAlienParent(next)
+ {
+ var parentWidget1 = new TestWidget("Parent");
+ var parentWidget2 = new TestWidget("Parent");
+ var childWidget = new TestWidget("Child");
+ childWidget.attach(parentWidget1);
+ try {
+ childWidget.showWidget(parentWidget2.element);
+ } catch (e) {
+ InspectorTest.addResult(e);
+ }
+ next();
}
]);
}

Powered by Google App Engine
This is Rietveld 408576698