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

Side by Side Diff: LayoutTests/fast/events/shadow-boundary-crossing.html

Issue 6914018: Merge 84587 - 2011-04-21 Dimitri Glazkov <dglazkov@chromium.org> (Closed) Base URL: http://svn.webkit.org/repository/webkit/branches/chromium/742/
Patch Set: Created 9 years, 7 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 | « LayoutTests/ChangeLog ('k') | LayoutTests/fast/events/shadow-boundary-crossing-expected.txt » ('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> 3 <script>
4 4
5 var logDiv; 5 var logDiv;
6 6
7 function log(msg, success) 7 function log(msg, success)
8 { 8 {
9 logDiv.appendChild(document.createElement('div')).textContent = msg + ': ' + (success ? 'PASS' : 'FAIL'); 9 logDiv.appendChild(document.createElement('div')).textContent = msg + ': ' + (success ? 'PASS' : 'FAIL');
10 } 10 }
(...skipping 96 matching lines...) Expand 10 before | Expand all | Expand 10 after
107 document.body.addEventListener('mouseout', countEventDispatch, false); 107 document.body.addEventListener('mouseout', countEventDispatch, false);
108 108
109 moveOverRightQuarterOf(fileInput); 109 moveOverRightQuarterOf(fileInput);
110 110
111 log("The mouseover/mouseout event between two elements inside the same s hadow subtree should not propagate out of the shadow DOM", count == 0); 111 log("The mouseover/mouseout event between two elements inside the same s hadow subtree should not propagate out of the shadow DOM", count == 0);
112 112
113 document.body.removeEventListener('mouseover', countEventDispatch, false ); 113 document.body.removeEventListener('mouseover', countEventDispatch, false );
114 document.body.removeEventListener('mouseout', countEventDispatch, false) ; 114 document.body.removeEventListener('mouseout', countEventDispatch, false) ;
115 fileInput.parentNode.removeChild(fileInput); 115 fileInput.parentNode.removeChild(fileInput);
116 }, 116 },
117 mouseOverOnHost: function()
118 {
119 var count = 0;
120 var input = document.body.appendChild(document.createElement('input'));
121 var countEventDispatch = function()
122 {
123 count++;
124 }
125
126 moveOver(document.body);
127 input.addEventListener('mouseover', countEventDispatch, false);
128 moveOver(input);
129
130 log("The mouseover/mouseout event on a shadow subtree host should propag ate out of the shadow DOM", count == 1);
131
132 document.body.removeEventListener('mouseover', countEventDispatch, false );
133 input.parentNode.removeChild(input);
134 },
117 labelSyntheticClick: function() 135 labelSyntheticClick: function()
118 { 136 {
119 var count = 0; 137 var count = 0;
120 var label = document.body.appendChild(document.createElement('label')); 138 var label = document.body.appendChild(document.createElement('label'));
121 var searchInput = label.appendChild(document.createElement('input')); 139 var searchInput = label.appendChild(document.createElement('input'));
122 searchInput.setAttribute('type', 'search'); 140 searchInput.setAttribute('type', 'search');
123 searchInput.setAttribute('id', 'baz'); 141 searchInput.setAttribute('id', 'baz');
124 label.setAttribute('for', 'baz'); 142 label.setAttribute('for', 'baz');
125 searchInput.addEventListener('click', function(e) 143 searchInput.addEventListener('click', function(e)
126 { 144 {
(...skipping 85 matching lines...) Expand 10 before | Expand all | Expand 10 after
212 } 230 }
213 231
214 </script> 232 </script>
215 </head> 233 </head>
216 <body onload="runTest()"> 234 <body onload="runTest()">
217 <p>Tests to ensure that shadow DOM boundary is not crossed during event prop agation. Can only run within DRT. 235 <p>Tests to ensure that shadow DOM boundary is not crossed during event prop agation. Can only run within DRT.
218 <p>See <a href="https://bugs.webkit.org/show_bug.cgi?id=46015">bug 46015</a> for details. 236 <p>See <a href="https://bugs.webkit.org/show_bug.cgi?id=46015">bug 46015</a> for details.
219 <div id="log"></div> 237 <div id="log"></div>
220 </body> 238 </body>
221 </html> 239 </html>
OLDNEW
« no previous file with comments | « LayoutTests/ChangeLog ('k') | LayoutTests/fast/events/shadow-boundary-crossing-expected.txt » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698