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

Side by Side Diff: LayoutTests/fast/dom/MutationObserver/end-of-task-delivery.html

Issue 12317072: Merge 143386 (Closed) Base URL: http://svn.webkit.org/repository/webkit/branches/chromium/1410/
Patch Set: Created 7 years, 10 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
OLDNEW
1 <!DOCTYPE html> 1 <!DOCTYPE html>
2 <ol contenteditable> 2 <ol contenteditable>
3 <li>Press enter 3 <li>Press enter
4 </ol> 4 </ol>
5 <p>Then click here</p> 5 <p>Then click here</p>
6 <script> 6 <script>
7 if (window.testRunner) { 7 if (window.testRunner) {
8 testRunner.dumpAsText(); 8 testRunner.dumpAsText();
9 testRunner.waitUntilDone(); 9 testRunner.waitUntilDone();
10 } 10 }
11 11
12 var list = document.querySelector('ol'); 12 var list = document.querySelector('ol');
13 var p = document.querySelector('p'); 13 var p = document.querySelector('p');
14 var observerRuns = 0; 14 var observerRuns = 0;
15 var observer = new WebKitMutationObserver(function() { ++observerRuns; }); 15 var observer = new MutationObserver(function() { ++observerRuns; });
16 observer.observe(list, {childList: true}); 16 observer.observe(list, {childList: true});
17 list.addEventListener('blur', function() { 17 list.addEventListener('blur', function() {
18 document.body.innerHTML = observerRuns == 1 ? 'PASSED' : 'FAILED'; 18 document.body.innerHTML = observerRuns == 1 ? 'PASSED' : 'FAILED';
19 if (window.testRunner) 19 if (window.testRunner)
20 testRunner.notifyDone(); 20 testRunner.notifyDone();
21 }); 21 });
22 list.focus(); 22 list.focus();
23 if (window.eventSender) { 23 if (window.eventSender) {
24 eventSender.scheduleAsynchronousKeyDown('\n'); 24 eventSender.scheduleAsynchronousKeyDown('\n');
25 eventSender.mouseMoveTo(p.offsetLeft + p.offsetWidth / 2, p.offsetTop + p.offsetHeight / 2); 25 eventSender.mouseMoveTo(p.offsetLeft + p.offsetWidth / 2, p.offsetTop + p.offsetHeight / 2);
26 eventSender.scheduleAsynchronousClick(); 26 eventSender.scheduleAsynchronousClick();
27 } 27 }
28 </script> 28 </script>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698