Title: [186152] trunk/Source/WebKit2
- Revision
- 186152
- Author
- [email protected]
- Date
- 2015-06-30 17:39:22 -0700 (Tue, 30 Jun 2015)
Log Message
[iOS] Ignore viewport rect changes during zoom bouncing.
<https://webkit.org/b/146480>
Reviewed by Benjamin Poulain.
When the user has pinch-zoomed past the maximum zoom scale and lets go of the screen,
we animate a bounce back to the maximum scale.
Suppress viewport rect updates during this bounce animation since we don't need them
anyway. This fixes an issue where we'd sometimes get a weird rect during the animation
and if could send that to the web process, causing it to generate tiles for a part of
the page that's not actually exposed.
* UIProcess/API/Cocoa/WKWebView.mm:
(-[WKWebView _updateVisibleContentRects]):
Modified Paths
Diff
Modified: trunk/Source/WebKit2/ChangeLog (186151 => 186152)
--- trunk/Source/WebKit2/ChangeLog 2015-07-01 00:36:18 UTC (rev 186151)
+++ trunk/Source/WebKit2/ChangeLog 2015-07-01 00:39:22 UTC (rev 186152)
@@ -1,3 +1,21 @@
+2015-06-30 Andreas Kling <[email protected]>
+
+ [iOS] Ignore viewport rect changes during zoom bouncing.
+ <https://webkit.org/b/146480>
+
+ Reviewed by Benjamin Poulain.
+
+ When the user has pinch-zoomed past the maximum zoom scale and lets go of the screen,
+ we animate a bounce back to the maximum scale.
+
+ Suppress viewport rect updates during this bounce animation since we don't need them
+ anyway. This fixes an issue where we'd sometimes get a weird rect during the animation
+ and if could send that to the web process, causing it to generate tiles for a part of
+ the page that's not actually exposed.
+
+ * UIProcess/API/Cocoa/WKWebView.mm:
+ (-[WKWebView _updateVisibleContentRects]):
+
2015-06-30 Enrica Casucci <[email protected]>
<rdar://problem/20655729> WebKit should heuristically exclude scrolling touch events from the user gesture category
Modified: trunk/Source/WebKit2/UIProcess/API/Cocoa/WKWebView.mm (186151 => 186152)
--- trunk/Source/WebKit2/UIProcess/API/Cocoa/WKWebView.mm 2015-07-01 00:36:18 UTC (rev 186151)
+++ trunk/Source/WebKit2/UIProcess/API/Cocoa/WKWebView.mm 2015-07-01 00:39:22 UTC (rev 186152)
@@ -1583,6 +1583,9 @@
if (_needsResetViewStateAfterCommitLoadForMainFrame)
return;
+ if ([_scrollView isZoomBouncing])
+ return;
+
CGRect fullViewRect = self.bounds;
CGRect visibleRectInContentCoordinates = _frozenVisibleContentRect ? _frozenVisibleContentRect.value() : [self convertRect:fullViewRect toView:_contentView.get()];
@@ -1591,7 +1594,7 @@
CGFloat scaleFactor = contentZoomScale(self);
- BOOL isStableState = !(_isChangingObscuredInsetsInteractively || [_scrollView isDragging] || [_scrollView isDecelerating] || [_scrollView isZooming] || [_scrollView isZoomBouncing] || [_scrollView _isAnimatingZoom] || [_scrollView _isScrollingToTop] || [self _scrollViewIsRubberBanding]);
+ BOOL isStableState = !(_isChangingObscuredInsetsInteractively || [_scrollView isDragging] || [_scrollView isDecelerating] || [_scrollView isZooming] || [_scrollView _isAnimatingZoom] || [_scrollView _isScrollingToTop] || [self _scrollViewIsRubberBanding]);
// FIXME: this can be made static after we stop supporting iOS 8.x.
if (isStableState && [_scrollView respondsToSelector:@selector(_isInterruptingDeceleration)])
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes