OLD | NEW |
1 <!DOCTYPE html> | 1 <!DOCTYPE html> |
2 <html> | 2 <html> |
3 <head> | 3 <head> |
4 <meta charset="utf-8"> | 4 <meta charset="utf-8"> |
5 <title>Scroll customization methods are called appropriately.</title> | 5 <title>Scroll customization methods are called appropriately.</title> |
6 <script src="../../../resources/testharness.js"></script> | 6 <script src="../../../resources/testharness.js"></script> |
7 <script src="../../../resources/testharnessreport.js"></script> | 7 <script src="../../../resources/testharnessreport.js"></script> |
8 <style> | 8 <style> |
9 | 9 |
10 * { | 10 * { |
(...skipping 190 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
201 function assertScrollTops(cTop, aTop, scrollingElementTop, step) { | 201 function assertScrollTops(cTop, aTop, scrollingElementTop, step) { |
202 assert_equals(c.scrollTop, cTop, "For id 'c' on step " + step); | 202 assert_equals(c.scrollTop, cTop, "For id 'c' on step " + step); |
203 assert_equals(a.scrollTop, aTop, "For id 'a' on step " + step); | 203 assert_equals(a.scrollTop, aTop, "For id 'a' on step " + step); |
204 assert_equals(document.scrollingElement.scrollTop, scrollingElementTop, "F
or scrollingElement on step " + step); | 204 assert_equals(document.scrollingElement.scrollTop, scrollingElementTop, "F
or scrollingElement on step " + step); |
205 }; | 205 }; |
206 | 206 |
207 assertScrollTops(0, 0, 0, 0); | 207 assertScrollTops(0, 0, 0, 0); |
208 | 208 |
209 var frame_actions = [ | 209 var frame_actions = [ |
210 function() { | 210 function() { |
| 211 // Touchscreen GFS arrives when there is an ongoing scroll. |
| 212 eventSender.gestureScrollBegin(10, 10); |
211 eventSender.gestureFlingStart(10, 10, -1000000, -1000000, "touchscreen")
; | 213 eventSender.gestureFlingStart(10, 10, -1000000, -1000000, "touchscreen")
; |
212 }, | 214 }, |
213 flingTest.step_func(function() { | 215 flingTest.step_func(function() { |
214 assertScrollTops(100, 0, 0, 1); | 216 assertScrollTops(100, 0, 0, 1); |
215 }), | 217 }), |
216 flingTest.step_func(function() { | 218 flingTest.step_func(function() { |
217 assertScrollTops(100, 0, 0, 2); | 219 assertScrollTops(100, 0, 0, 2); |
218 }), | 220 }), |
219 flingTest.step_func(function() { | 221 flingTest.step_func(function() { |
220 assertScrollTops(100, 0, 0, 3); | 222 assertScrollTops(100, 0, 0, 3); |
(...skipping 16 matching lines...) Expand all Loading... |
237 window.requestAnimationFrame(raf); | 239 window.requestAnimationFrame(raf); |
238 } | 240 } |
239 | 241 |
240 executeFrameActions(frame_actions); | 242 executeFrameActions(frame_actions); |
241 } | 243 } |
242 } | 244 } |
243 | 245 |
244 </script> | 246 </script> |
245 </body> | 247 </body> |
246 </html> | 248 </html> |
OLD | NEW |