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

Side by Side Diff: third_party/WebKit/LayoutTests/inspector/elements/styles-1/css-outline.html

Issue 2572053002: DevTools: kill SDK.CSSParser (Closed)
Patch Set: address comments Created 4 years 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 unified diff | Download patch
« no previous file with comments | « no previous file | third_party/WebKit/Source/devtools/BUILD.gn » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 <html> 1 <html>
2 <head> 2 <head>
3 <script src="../../../http/tests/inspector/inspector-test.js"></script> 3 <script src="../../../http/tests/inspector/inspector-test.js"></script>
4 <style id="styler"> 4 <style id="styler">
5 @import url("some-url-to-load-css.css") print; 5 @import url("some-url-to-load-css.css") print;
6 @charset "ISO-8859-15"; 6 @charset "ISO-8859-15";
7 @namespace svg url(http://www.w3.org/2000/svg); 7 @namespace svg url(http://www.w3.org/2000/svg);
8 @font-face { 8 @font-face {
9 font-family: "Example Font"; 9 font-family: "Example Font";
10 src: url("http://www.example.com/fonts/example"); 10 src: url("http://www.example.com/fonts/example");
(...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after
53 </style> 53 </style>
54 <script> 54 <script>
55 55
56 function getCSS() 56 function getCSS()
57 { 57 {
58 return document.querySelector("#styler").textContent; 58 return document.querySelector("#styler").textContent;
59 } 59 }
60 60
61 function test() 61 function test()
62 { 62 {
63 function onStyleSheetParsed(rules) 63 function onRulesParsed(isLastChunk, rules)
64 { 64 {
65 for (var i = 0; i < rules.length; ++i) 65 for (var i = 0; i < rules.length; ++i)
66 InspectorTest.addObject(rules[i]); 66 InspectorTest.addObject(rules[i]);
67 InspectorTest.completeTest(); 67 if (isLastChunk)
68 InspectorTest.completeTest();
68 } 69 }
69 70
70 function onStyleFetched(result) 71 function onStyleFetched(result)
71 { 72 {
72 var parser = new SDK.CSSParser(); 73 Common.formatterWorkerPool.parseCSS(result.value, onRulesParsed);
73 parser.parse(result.value, onStyleSheetParsed);
74 } 74 }
75 75
76 InspectorTest.evaluateInPage("getCSS()", onStyleFetched); 76 InspectorTest.evaluateInPage("getCSS()", onStyleFetched);
77 } 77 }
78 78
79 </script> 79 </script>
80 80
81 </head> 81 </head>
82 82
83 <body onload="runTest()"> 83 <body onload="runTest()">
84 <p>The test verifies the CSS outline functionality.</p> 84 <p>The test verifies the CSS outline functionality.</p>
85 </body> 85 </body>
86 </html> 86 </html>
OLDNEW
« no previous file with comments | « no previous file | third_party/WebKit/Source/devtools/BUILD.gn » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698