Title: [170036] trunk/Source/WebKit2
Revision
170036
Author
[email protected]
Date
2014-06-16 16:48:13 -0700 (Mon, 16 Jun 2014)

Log Message

[iOS][wk2] Swipe snapshots are removed too quickly if there is no saved render tree size
https://bugs.webkit.org/show_bug.cgi?id=133891

Reviewed by Simon Fraser.

* UIProcess/ios/ViewGestureControllerIOS.mm:
(WebKit::ViewGestureController::endSwipeGesture):
(WebKit::ViewGestureController::setRenderTreeSize):
If we don't know the target render tree size, wait until the first layer tree commit
that comes in, instead of removing the snapshot when the gesture ends.

Modified Paths

Diff

Modified: trunk/Source/WebKit2/ChangeLog (170035 => 170036)


--- trunk/Source/WebKit2/ChangeLog	2014-06-16 23:45:27 UTC (rev 170035)
+++ trunk/Source/WebKit2/ChangeLog	2014-06-16 23:48:13 UTC (rev 170036)
@@ -1,5 +1,18 @@
 2014-06-16  Timothy Horton  <[email protected]>
 
+        [iOS][wk2] Swipe snapshots are removed too quickly if there is no saved render tree size
+        https://bugs.webkit.org/show_bug.cgi?id=133891
+
+        Reviewed by Simon Fraser.
+
+        * UIProcess/ios/ViewGestureControllerIOS.mm:
+        (WebKit::ViewGestureController::endSwipeGesture):
+        (WebKit::ViewGestureController::setRenderTreeSize):
+        If we don't know the target render tree size, wait until the first layer tree commit
+        that comes in, instead of removing the snapshot when the gesture ends.
+
+2014-06-16  Timothy Horton  <[email protected]>
+
         [iOS][wk2] Swiping back briefly shows the previous page before loading the new one
         https://bugs.webkit.org/show_bug.cgi?id=133885
 

Modified: trunk/Source/WebKit2/UIProcess/ios/ViewGestureControllerIOS.mm (170035 => 170036)


--- trunk/Source/WebKit2/UIProcess/ios/ViewGestureControllerIOS.mm	2014-06-16 23:45:27 UTC (rev 170035)
+++ trunk/Source/WebKit2/UIProcess/ios/ViewGestureControllerIOS.mm	2014-06-16 23:48:13 UTC (rev 170036)
@@ -236,11 +236,6 @@
     ViewSnapshotStore::shared().disableSnapshotting();
     m_webPageProxy.goToBackForwardItem(targetItem);
     ViewSnapshotStore::shared().enableSnapshotting();
-    
-    if (!m_snapshotRemovalTargetRenderTreeSize) {
-        removeSwipeSnapshot();
-        return;
-    }
 
     m_swipeWatchdogTimer.startOneShot(swipeSnapshotRemovalWatchdogDuration.count());
 }
@@ -253,7 +248,7 @@
     // Don't remove the swipe snapshot until we get a drawing area transaction more recent than the navigation,
     // and we hit the render tree size threshold. This avoids potentially removing the snapshot early,
     // when receiving commits from the previous (pre-navigation) page.
-    if (m_snapshotRemovalTargetRenderTreeSize && renderTreeSize > m_snapshotRemovalTargetRenderTreeSize && m_webPageProxy.drawingArea()->lastVisibleTransactionID() >= m_snapshotRemovalTargetTransactionID)
+    if ((!m_snapshotRemovalTargetRenderTreeSize || renderTreeSize > m_snapshotRemovalTargetRenderTreeSize) && m_webPageProxy.drawingArea()->lastVisibleTransactionID() >= m_snapshotRemovalTargetTransactionID)
         removeSwipeSnapshot();
 }
 
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to