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

Side by Side Diff: LayoutTests/compositing/overflow/resources/automatically-opt-into-composited-scrolling.js

Issue 14741004: NOT FOR REVIEW - Update comp-scrolling state at a well defined point in the pipeline. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Added annotations describing how this patch will be split. Created 7 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 | Annotate | Revision Log
OLDNEW
1 var debugMode = false; 1 var debugMode = false;
2 2
3 if (window.testRunner) 3 if (window.testRunner)
4 testRunner.dumpAsText(); 4 testRunner.dumpAsText();
5 5
6 function write(str) 6 function write(str)
7 { 7 {
8 var pre = document.getElementById('console'); 8 var pre = document.getElementById('console');
9 var text = document.createTextNode(str + '\n'); 9 var text = document.createTextNode(str + '\n');
10 pre.appendChild(text); 10 pre.appendChild(text);
(...skipping 139 matching lines...) Expand 10 before | Expand all | Expand 10 after
150 150
151 // We want the first descendant succeeding us in the ordering to get 151 // We want the first descendant succeeding us in the ordering to get
152 // z-index: 0. 152 // z-index: 0.
153 if (numElementsWithZIndexZero === 3) { 153 if (numElementsWithZIndexZero === 3) {
154 if (firstChildIndex > containerIndex) 154 if (firstChildIndex > containerIndex)
155 ordering[firstChildIndex].style.zIndex = '0'; 155 ordering[firstChildIndex].style.zIndex = '0';
156 else 156 else
157 ordering[secondChildIndex].style.zIndex = '0'; 157 ordering[secondChildIndex].style.zIndex = '0';
158 } 158 }
159 159
160 // PATCH 1
161 if (debugMode) {
162 write('permutationIteration: ' + permutationIteration);
163 write('hasPositionedAncestor ' + hasPositionedAncestor);
164 write('ancestor, z-index: ' + ancestor.style.zIndex + ', position: ' + ancestor.style.position + ', display: ' + ancestor.style.display);
165 write('predecessor, z-index: ' + predecessor.style.zIndex + ', positio n: ' + predecessor.style.position + ', display: ' + predecessor.style.display);
166 write('successor, z-index: ' + successor.style.zIndex + ', position: ' + successor.style.position + ', display: ' + successor.style.display);
167 write('firstChild, z-index: ' + firstChild.style.zIndex + ', position: ' + firstChild.style.position + ', display: ' + firstChild.style.display);
168 write('secondChild, z-index: ' + secondChild.style.zIndex + ', positio n: ' + secondChild.style.position + ', display: ' + secondChild.style.display);
169 write('container, z-index: ' + container.style.zIndex + ', position: ' + container.style.position + ', display: ' + container.style.display);
170 write('');
171 }
172
160 testPermutation(permutationIteration, ordering, hasPositionedAncestor, c ontainerIsPositioned); 173 testPermutation(permutationIteration, ordering, hasPositionedAncestor, c ontainerIsPositioned);
161 permutationIteration++; 174 permutationIteration++;
162 } 175 }
163 } 176 }
164 } 177 }
165 } 178 }
166 179
167 function permute(testPermutation) 180 function permute(testPermutation)
168 { 181 {
169 var ancestor = document.getElementById('ancestor'); 182 var ancestor = document.getElementById('ancestor');
(...skipping 13 matching lines...) Expand all
183 containerIndices.splice(containerSubindex, 1); 196 containerIndices.splice(containerSubindex, 1);
184 var firstChildIndex = containerIndices[0]; 197 var firstChildIndex = containerIndices[0];
185 var secondChildIndex = containerIndices[1]; 198 var secondChildIndex = containerIndices[1];
186 199
187 permuteWithFixedOrdering(testPermutation, siblingIndex, containerIndex, fi rstChildIndex, secondChildIndex, 1); 200 permuteWithFixedOrdering(testPermutation, siblingIndex, containerIndex, fi rstChildIndex, secondChildIndex, 1);
188 permuteWithFixedOrdering(testPermutation, siblingIndex, containerIndex, fi rstChildIndex, secondChildIndex, 2); 201 permuteWithFixedOrdering(testPermutation, siblingIndex, containerIndex, fi rstChildIndex, secondChildIndex, 2);
189 permuteWithFixedOrdering(testPermutation, siblingIndex, containerIndex, fi rstChildIndex, secondChildIndex, 3); 202 permuteWithFixedOrdering(testPermutation, siblingIndex, containerIndex, fi rstChildIndex, secondChildIndex, 3);
190 } 203 }
191 } 204 }
192 } // function doTest 205 } // function doTest
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698