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

Side by Side Diff: third_party/WebKit/LayoutTests/paint/spellmarkers/document-markers-zoom-250.html

Issue 2737643002: Use internals.setMarker in layout tests in paint/spellmarkers/ (Closed)
Patch Set: Created 3 years, 9 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 unified diff | Download patch
« no previous file with comments | « third_party/WebKit/LayoutTests/paint/spellmarkers/document-markers-zoom-200.html ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 <!DOCTYPE html> 1 <!DOCTYPE html>
2 <html> 2 <html>
3 <head> 3 <head>
4 <style> 4 <style>
5 #editable { zoom: 250%; } 5 #editable { zoom: 250%; }
6 </style> 6 </style>
7 <script> 7 <script>
8 if (window.testRunner) {
9 testRunner.setMockSpellCheckerEnabled(true);
10 }
11
12 function runTest() { 8 function runTest() {
13 editable = document.getElementById("editable"); 9 const editable = document.getElementById("editable");
14 selection = document.getSelection(); 10 getSelection().selectAllChildren(editable);
15 selection.addRange(new Range); 11 if (window.internals) {
16 range = selection.getRangeAt(0); 12 const range = document.createRange();
17 range.selectNodeContents(editable); 13 range.setStart(editable.firstChild, 0);
14 range.setEnd(editable.firstChild, 8);
15 internals.setMarker(document, range, 'spelling');
16 }
18 } 17 }
19 </script> 18 </script>
20 </head> 19 </head>
21 <body onload="runTest();"> 20 <body onload="runTest();">
22 <div id="editable" contenteditable="true">wellcome should be marked</div> 21 <div id="editable" contenteditable="true">wellcome should be marked</div>
23 </body> 22 </body>
24 </html> 23 </html>
OLDNEW
« no previous file with comments | « third_party/WebKit/LayoutTests/paint/spellmarkers/document-markers-zoom-200.html ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698