Index: LayoutTests/fast/events/touch/gesture/touch-gesture-scroll-page-zoomed.html |
diff --git a/LayoutTests/fast/events/touch/gesture/touch-gesture-scroll-page.html b/LayoutTests/fast/events/touch/gesture/touch-gesture-scroll-page-zoomed.html |
similarity index 73% |
copy from LayoutTests/fast/events/touch/gesture/touch-gesture-scroll-page.html |
copy to LayoutTests/fast/events/touch/gesture/touch-gesture-scroll-page-zoomed.html |
index 29457952f7c28283be90121591a531047f4fa103..826045402be266d05c792a03a2d6f13b837a0cd6 100644 |
--- a/LayoutTests/fast/events/touch/gesture/touch-gesture-scroll-page.html |
+++ b/LayoutTests/fast/events/touch/gesture/touch-gesture-scroll-page-zoomed.html |
@@ -43,7 +43,7 @@ td { |
var expectedGesturesTotal = 2; |
var gesturesOccurred = 0; |
var scrollAmountX = ['0', '0']; |
-var scrollAmountY = ['70', '130']; |
+var scrollAmountY = ['140', '40']; |
var wheelEventsOccurred = 0; |
var expectedWheelEventsOccurred = ['0', '0']; |
var scrollEventsOccurred = 0; |
@@ -52,19 +52,19 @@ var scrollEventsOccurred = 0; |
var expectedScrollEventsOccurred = '1'; |
function recordScroll(event) { |
- debug('scroll event ' + scrollEventsOccurred + '+> ' + event.target); |
- scrollEventsOccurred++; |
- |
- if (window.eventSender) { |
- // Because scroll events arrive asynchronously, only one will arrive. |
- if (gesturesOccurred == expectedGesturesTotal) { |
- shouldBe('scrollEventsOccurred', expectedScrollEventsOccurred); |
- // If we've got here, we've passed. |
- successfullyParsed = true; |
- isSuccessfullyParsed(); |
- if (window.testRunner) |
- testRunner.notifyDone(); |
- } |
+ debug('scroll event ' + scrollEventsOccurred + '+> ' + event.target); |
+ scrollEventsOccurred++; |
+ |
+ if (window.eventSender) { |
+ // Because scroll events arrive asynchronously, only one will arrive. |
+ if (gesturesOccurred == expectedGesturesTotal) { |
+ shouldBe('scrollEventsOccurred', expectedScrollEventsOccurred); |
+ // If we've got here, we've passed. |
+ successfullyParsed = true; |
+ isSuccessfullyParsed(); |
+ if (window.testRunner) |
+ testRunner.notifyDone(); |
+ } |
} |
} |
@@ -74,7 +74,7 @@ function buildPage() |
var table = document.getElementById('table_to_fill'); |
var targetHeight = document.body.offsetHeight; |
var cellPairHeight = table.offsetHeight; |
- var numberOfReps = targetHeight / cellPairHeight * 2; |
+ var numberOfReps = targetHeight / cellPairHeight * 4; |
var i; |
for (i = 0; i < numberOfReps; i++) { |
var p = document.createElement('tr'); |
@@ -92,6 +92,8 @@ function buildPage() |
function firstGestureScroll() |
{ |
debug("first gesture"); |
+ |
+ window.internals.setZoomFactor(0.5); |
eventSender.gestureScrollBegin(10, 72); |
eventSender.gestureScrollUpdate(0, -30); |
eventSender.gestureScrollUpdate(0, -40); |
@@ -104,9 +106,15 @@ function firstGestureScroll() |
function secondGestureScroll() |
{ |
debug("second gesture"); |
+ |
+ eventSender.gestureScrollBegin(10, 72); |
+ eventSender.gestureScrollUpdate(0, 200); |
+ eventSender.gestureScrollEnd(0, 0); |
+ |
+ window.internals.setZoomFactor(2.0); |
eventSender.gestureScrollBegin(800, 40); |
- eventSender.gestureScrollUpdate(0, -30); |
- eventSender.gestureScrollUpdate(0, -30); |
+ eventSender.gestureScrollUpdate(0, -40); |
+ eventSender.gestureScrollUpdate(0, -40); |
eventSender.gestureScrollEnd(0, 0); |
// Wait for layout. |
@@ -120,7 +128,7 @@ function runTest() |
{ |
buildPage(); |
if (window.eventSender) { |
- description('This tests scroll gesture event scrolling on a whole page.'); |
+ description('This tests scroll gesture event scrolling on a whole page with browser zoom.'); |
if (checkTestDependencies()) |
firstGestureScroll(); |
else |