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

Side by Side Diff: LayoutTests/fast/events/touch/gesture/touch-gesture-fling-with-page-scale.html

Issue 901323004: Pass source device to window.eventSender.gestureFlingStart. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 5 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
« no previous file with comments | « LayoutTests/fast/events/touch/gesture/pad-gesture-fling.js ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 <!DOCTYPE html> 1 <!DOCTYPE html>
2 2
3 <script src="../../../../resources/js-test.js"></script> 3 <script src="../../../../resources/js-test.js"></script>
4 <script> 4 <script>
5 if (window.testRunner && window.eventSender) { 5 if (window.testRunner && window.eventSender) {
6 window.jsTestIsAsync = true; 6 window.jsTestIsAsync = true;
7 testRunner.waitUntilDone(); 7 testRunner.waitUntilDone();
8 } 8 }
9 9
10 var direction; 10 var direction;
(...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after
55 55
56 var verticalFlingOverContainer = function() { 56 var verticalFlingOverContainer = function() {
57 direction = 'VERTICAL'; 57 direction = 'VERTICAL';
58 shouldScrollContainer = true; 58 shouldScrollContainer = true;
59 eventSender.gestureFlingCancel(); 59 eventSender.gestureFlingCancel();
60 resetViewport(); 60 resetViewport();
61 eventSender.gestureFlingStart( 61 eventSender.gestureFlingStart(
62 containerPinchCoordsX, 62 containerPinchCoordsX,
63 containerPinchCoordsY + container.offsetHeight*scale, 63 containerPinchCoordsY + container.offsetHeight*scale,
64 0, 64 0,
65 10000); 65 10000,
66 "touchpad");
Rick Byers 2015/02/07 11:22:47 this test is in the touchscreen directly - perhaps
tdresser 2015/02/09 13:56:51 See the test description: "To test manually, pinc
66 } 67 }
67 68
68 var horizontalFlingOverContainer = function() { 69 var horizontalFlingOverContainer = function() {
69 direction = 'HORIZONTAL'; 70 direction = 'HORIZONTAL';
70 shouldScrollContainer = true; 71 shouldScrollContainer = true;
71 eventSender.gestureFlingCancel(); 72 eventSender.gestureFlingCancel();
72 resetViewport(); 73 resetViewport();
73 eventSender.gestureFlingStart( 74 eventSender.gestureFlingStart(
74 containerPinchCoordsX + container.offsetWidth*scale, 75 containerPinchCoordsX + container.offsetWidth*scale,
75 containerPinchCoordsY, 76 containerPinchCoordsY,
76 10000, 77 10000,
77 0); 78 0,
79 "touchpad");
78 } 80 }
79 81
80 var verticalFlingNotOverContainer = function() { 82 var verticalFlingNotOverContainer = function() {
81 direction = 'VERTICAL'; 83 direction = 'VERTICAL';
82 shouldScrollContainer = false; 84 shouldScrollContainer = false;
83 eventSender.gestureFlingCancel(); 85 eventSender.gestureFlingCancel();
84 resetViewport(); 86 resetViewport();
85 eventSender.gestureFlingStart( 87 eventSender.gestureFlingStart(
86 containerPinchCoordsX + container.offsetWidth*scale, 88 containerPinchCoordsX + container.offsetWidth*scale,
87 0, 89 0,
88 0, 90 0,
89 -10000); 91 -10000,
92 "touchpad");
90 } 93 }
91 94
92 var horizontalFlingNotOverContainer = function() { 95 var horizontalFlingNotOverContainer = function() {
93 direction = 'HORIZONTAL'; 96 direction = 'HORIZONTAL';
94 shouldScrollContainer = false; 97 shouldScrollContainer = false;
95 eventSender.gestureFlingCancel(); 98 eventSender.gestureFlingCancel();
96 resetViewport(); 99 resetViewport();
97 eventSender.gestureFlingStart( 100 eventSender.gestureFlingStart(
98 0, 101 0,
99 containerPinchCoordsY + container.offsetHeight*scale, 102 containerPinchCoordsY + container.offsetHeight*scale,
100 -10000, 103 -10000,
101 0); 104 0,
105 "touchpad");
102 } 106 }
103 107
104 var scrollHandler = function() { 108 var scrollHandler = function() {
105 if (direction === 'VERTICAL') { 109 if (direction === 'VERTICAL') {
106 if (shouldScrollContainer) { 110 if (shouldScrollContainer) {
107 if (window.scrollY == 0) { 111 if (window.scrollY == 0) {
108 debug("Mouse was over container, it should have scrolled back to 0"); 112 debug("Mouse was over container, it should have scrolled back to 0");
109 shouldBe('container.scrollTop', '0'); 113 shouldBe('container.scrollTop', '0');
110 requestAnimationFrame(verticalFlingNotOverContainer); 114 requestAnimationFrame(verticalFlingNotOverContainer);
111 } 115 }
(...skipping 71 matching lines...) Expand 10 before | Expand all | Expand 10 after
183 <div class="greenbox"></div> 187 <div class="greenbox"></div>
184 <div class="redbox"></div> 188 <div class="redbox"></div>
185 <div class="greenbox"></div> 189 <div class="greenbox"></div>
186 <div class="redbox"></div> 190 <div class="redbox"></div>
187 <div class="greenbox"></div> 191 <div class="greenbox"></div>
188 <div class="redbox"></div> 192 <div class="redbox"></div>
189 <div class="greenbox"></div> 193 <div class="greenbox"></div>
190 <div class="redbox"></div> 194 <div class="redbox"></div>
191 <div class="greenbox"></div> 195 <div class="greenbox"></div>
192 </div> 196 </div>
OLDNEW
« no previous file with comments | « LayoutTests/fast/events/touch/gesture/pad-gesture-fling.js ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698