| Index: LayoutTests/http/tests/inspector/elements/styles/edit-css-with-source-url.html
|
| diff --git a/LayoutTests/http/tests/inspector/elements/styles/edit-css-with-source-url.html b/LayoutTests/http/tests/inspector/elements/styles/edit-css-with-source-url.html
|
| index be8c87027bc31e2c1d2b0f4a8fe5e3823cb22879..f07a40b0d8f8474e4c97c91efec822854dda0003 100644
|
| --- a/LayoutTests/http/tests/inspector/elements/styles/edit-css-with-source-url.html
|
| +++ b/LayoutTests/http/tests/inspector/elements/styles/edit-css-with-source-url.html
|
| @@ -33,12 +33,6 @@ function test()
|
| {
|
| var styleText = "#inspected {\n color: red;\n}\n";
|
|
|
| - function loadStylesheet(callback)
|
| - {
|
| - InspectorTest.addResult("Loading stylesheet with sourceURL:");
|
| - InspectorTest.evaluateInPage("loadStylesheet()", callback);
|
| - }
|
| -
|
| function dumpUISourceCodeContents()
|
| {
|
| InspectorTest.addResult("Dumping uiSourceCode content:");
|
| @@ -60,11 +54,14 @@ function test()
|
| function didShowScriptSource(sourceFrame)
|
| {
|
| dumpUISourceCodeContents();
|
| - loadStylesheet(stylesheetLoaded);
|
| + InspectorTest.addResult("Loading stylesheet with sourceURL:");
|
| + WebInspector.cssModel.addEventListener(WebInspector.CSSStyleModel.Events.StyleSheetAdded, stylesheetLoaded);
|
| + InspectorTest.evaluateInPage("loadStylesheet()");
|
| }
|
|
|
| function stylesheetLoaded()
|
| {
|
| + WebInspector.cssModel.removeEventListener(WebInspector.CSSStyleModel.Events.StyleSheetAdded, stylesheetLoaded);
|
| InspectorTest.addResult("Stylesheet loaded.");
|
| WebInspector.inspectorView.showPanel("elements");
|
| InspectorTest.selectNodeAndWaitForStyles("inspected", nodeSelected);
|
|
|