| OLD | NEW |
| 1 <!DOCTYPE html> | 1 <!DOCTYPE html> |
| 2 <html> | 2 <html> |
| 3 <head> | 3 <head> |
| 4 <style> | 4 <style> |
| 5 ::-webkit-scrollbar { | 5 ::-webkit-scrollbar { |
| 6 width: 0px; | 6 width: 0px; |
| 7 height: 0px; | 7 height: 0px; |
| 8 } | 8 } |
| 9 #bluebox { | 9 #bluebox { |
| 10 width: 100px; | 10 width: 100px; |
| (...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 48 } | 48 } |
| 49 eventSender.gestureScrollEnd(0, 0); | 49 eventSender.gestureScrollEnd(0, 0); |
| 50 | 50 |
| 51 expectedScrollDistance = Math.floor(20 - scrollDistance/scaleFactor); | 51 expectedScrollDistance = Math.floor(20 - scrollDistance/scaleFactor); |
| 52 | 52 |
| 53 shouldBe('scrollBox.scrollTop', 'expectedScrollDistance'); | 53 shouldBe('scrollBox.scrollTop', 'expectedScrollDistance'); |
| 54 } | 54 } |
| 55 | 55 |
| 56 function scaleWithEventSender(scaleFactor) { | 56 function scaleWithEventSender(scaleFactor) { |
| 57 var scaleOffset = 0; | 57 var scaleOffset = 0; |
| 58 if (window.internals) { | 58 if (window.eventSender) { |
| 59 window.internals.setPageScaleFactor(scaleFactor, scaleOffset, scale
Offset); | 59 window.eventSender.setPageScaleFactor(scaleFactor, scaleOffset, sca
leOffset); |
| 60 } | 60 } |
| 61 } | 61 } |
| 62 | 62 |
| 63 function test() { | 63 function test() { |
| 64 if (window.eventSender) { | 64 if (window.eventSender) { |
| 65 description('This tests that a div scrolled by gesture touch while
the page is scaled still scrolls at' + | 65 description('This tests that a div scrolled by gesture touch while
the page is scaled still scrolls at' + |
| 66 ' the rate of the touch'); | 66 ' the rate of the touch'); |
| 67 | 67 |
| 68 scrollBox = document.getElementById("scrollbox"); | 68 scrollBox = document.getElementById("scrollbox"); |
| 69 | 69 |
| (...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 103 <div id="redbox"></div> | 103 <div id="redbox"></div> |
| 104 <div id="bluebox"></div> | 104 <div id="bluebox"></div> |
| 105 <div id="redbox"></div> | 105 <div id="redbox"></div> |
| 106 <div id="bluebox"></div> | 106 <div id="bluebox"></div> |
| 107 <div id="redbox"></div> | 107 <div id="redbox"></div> |
| 108 </div> | 108 </div> |
| 109 | 109 |
| 110 <div id="console"></div> | 110 <div id="console"></div> |
| 111 </body> | 111 </body> |
| 112 </html> | 112 </html> |
| OLD | NEW |