Get rid of the DynamicSizeWithMinimumViewSize layout mode
authortimothy_horton@apple.com <timothy_horton@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 28 Aug 2015 18:09:49 +0000 (18:09 +0000)
committertimothy_horton@apple.com <timothy_horton@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 28 Aug 2015 18:09:49 +0000 (18:09 +0000)
https://bugs.webkit.org/show_bug.cgi?id=148554

Reviewed by Anders Carlsson.

* UIProcess/API/C/WKLayoutMode.h:
* UIProcess/API/Cocoa/WKViewPrivate.h:
* UIProcess/API/Cocoa/WKWebView.mm:
(-[WKWebView _layoutMode]):
(-[WKWebView _setLayoutMode:]):
(-[WKWebView _setMinimumViewSize:]): Deleted.
(-[WKWebView _minimumViewSize]): Deleted.
* UIProcess/API/Cocoa/WKWebViewPrivate.h:
* UIProcess/API/Cocoa/_WKLayoutMode.h:
* UIProcess/API/mac/WKView.mm:
(-[WKView _setMinimumViewSize:]): Deleted.
(-[WKView _minimumViewSize]): Deleted.
* UIProcess/WebPageProxy.cpp:
(WebKit::WebPageProxy::scaleViewAndUpdateGeometryFenced): Deleted.
* UIProcess/WebPageProxy.h:
* UIProcess/mac/WKViewLayoutStrategy.mm:
(+[WKViewLayoutStrategy layoutStrategyWithPage:view:mode:]):
(-[WKViewDynamicSizeWithMinimumViewSizeLayoutStrategy initWithPage:view:mode:]): Deleted.
(-[WKViewDynamicSizeWithMinimumViewSizeLayoutStrategy _updateTransientScale:]): Deleted.
(-[WKViewDynamicSizeWithMinimumViewSizeLayoutStrategy updateLayout]): Deleted.
(-[WKViewDynamicSizeWithMinimumViewSizeLayoutStrategy didChangeMinimumViewSize]): Deleted.
(-[WKViewDynamicSizeWithMinimumViewSizeLayoutStrategy willStartLiveResize]): Deleted.
(-[WKViewDynamicSizeWithMinimumViewSizeLayoutStrategy didEndLiveResize]): Deleted.
(-[WKViewDynamicSizeWithMinimumViewSizeLayoutStrategy didChangeFrameSize]): Deleted.
(-[WKViewDynamicSizeWithMinimumViewSizeLayoutStrategy willChangeLayoutStrategy]): Deleted.
* WebProcess/WebPage/DrawingArea.h:
(WebKit::DrawingArea::replyWithFenceAfterNextFlush): Deleted.
* WebProcess/WebPage/WebPage.cpp:
(WebKit::WebPage::scaleViewAndUpdateGeometryFenced): Deleted.
* WebProcess/WebPage/WebPage.h:
* WebProcess/WebPage/WebPage.messages.in:
* WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.h:
* WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.mm:
(WebKit::TiledCoreAnimationDrawingArea::replyWithFenceAfterNextFlush): Deleted.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@189105 268f45cc-cd09-0410-ab3c-d52691b4dbfc

17 files changed:
Source/WebKit2/ChangeLog
Source/WebKit2/UIProcess/API/C/WKLayoutMode.h
Source/WebKit2/UIProcess/API/Cocoa/WKViewPrivate.h
Source/WebKit2/UIProcess/API/Cocoa/WKWebView.mm
Source/WebKit2/UIProcess/API/Cocoa/WKWebViewPrivate.h
Source/WebKit2/UIProcess/API/Cocoa/_WKLayoutMode.h
Source/WebKit2/UIProcess/API/mac/WKView.mm
Source/WebKit2/UIProcess/WebPageProxy.cpp
Source/WebKit2/UIProcess/WebPageProxy.h
Source/WebKit2/UIProcess/mac/WKViewLayoutStrategy.h
Source/WebKit2/UIProcess/mac/WKViewLayoutStrategy.mm
Source/WebKit2/WebProcess/WebPage/DrawingArea.h
Source/WebKit2/WebProcess/WebPage/WebPage.cpp
Source/WebKit2/WebProcess/WebPage/WebPage.h
Source/WebKit2/WebProcess/WebPage/WebPage.messages.in
Source/WebKit2/WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.h
Source/WebKit2/WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.mm

index eb6f584..6f34ed4 100644 (file)
@@ -1,5 +1,47 @@
 2015-08-28  Timothy Horton  <timothy_horton@apple.com>
 
+        Get rid of the DynamicSizeWithMinimumViewSize layout mode
+        https://bugs.webkit.org/show_bug.cgi?id=148554
+
+        Reviewed by Anders Carlsson.
+
+        * UIProcess/API/C/WKLayoutMode.h:
+        * UIProcess/API/Cocoa/WKViewPrivate.h:
+        * UIProcess/API/Cocoa/WKWebView.mm:
+        (-[WKWebView _layoutMode]):
+        (-[WKWebView _setLayoutMode:]):
+        (-[WKWebView _setMinimumViewSize:]): Deleted.
+        (-[WKWebView _minimumViewSize]): Deleted.
+        * UIProcess/API/Cocoa/WKWebViewPrivate.h:
+        * UIProcess/API/Cocoa/_WKLayoutMode.h:
+        * UIProcess/API/mac/WKView.mm:
+        (-[WKView _setMinimumViewSize:]): Deleted.
+        (-[WKView _minimumViewSize]): Deleted.
+        * UIProcess/WebPageProxy.cpp:
+        (WebKit::WebPageProxy::scaleViewAndUpdateGeometryFenced): Deleted.
+        * UIProcess/WebPageProxy.h:
+        * UIProcess/mac/WKViewLayoutStrategy.mm:
+        (+[WKViewLayoutStrategy layoutStrategyWithPage:view:mode:]):
+        (-[WKViewDynamicSizeWithMinimumViewSizeLayoutStrategy initWithPage:view:mode:]): Deleted.
+        (-[WKViewDynamicSizeWithMinimumViewSizeLayoutStrategy _updateTransientScale:]): Deleted.
+        (-[WKViewDynamicSizeWithMinimumViewSizeLayoutStrategy updateLayout]): Deleted.
+        (-[WKViewDynamicSizeWithMinimumViewSizeLayoutStrategy didChangeMinimumViewSize]): Deleted.
+        (-[WKViewDynamicSizeWithMinimumViewSizeLayoutStrategy willStartLiveResize]): Deleted.
+        (-[WKViewDynamicSizeWithMinimumViewSizeLayoutStrategy didEndLiveResize]): Deleted.
+        (-[WKViewDynamicSizeWithMinimumViewSizeLayoutStrategy didChangeFrameSize]): Deleted.
+        (-[WKViewDynamicSizeWithMinimumViewSizeLayoutStrategy willChangeLayoutStrategy]): Deleted.
+        * WebProcess/WebPage/DrawingArea.h:
+        (WebKit::DrawingArea::replyWithFenceAfterNextFlush): Deleted.
+        * WebProcess/WebPage/WebPage.cpp:
+        (WebKit::WebPage::scaleViewAndUpdateGeometryFenced): Deleted.
+        * WebProcess/WebPage/WebPage.h:
+        * WebProcess/WebPage/WebPage.messages.in:
+        * WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.h:
+        * WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.mm:
+        (WebKit::TiledCoreAnimationDrawingArea::replyWithFenceAfterNextFlush): Deleted.
+
+2015-08-28  Timothy Horton  <timothy_horton@apple.com>
+
         [Mac] Right-clicking on GIFs spins the UI process for a while
         https://bugs.webkit.org/show_bug.cgi?id=148566
         <rdar://problem/22460854>
index 67266a4..bb75f17 100644 (file)
@@ -33,11 +33,10 @@ extern "C" {
 #endif
 
 enum {
-    kWKLayoutModeViewSize,
-    kWKLayoutModeFixedSize,
-    kWKLayoutModeDynamicSizeComputedFromViewScale,
-    kWKLayoutModeDynamicSizeWithMinimumViewSize,
-    kWKLayoutModeDynamicSizeComputedFromMinimumDocumentSize
+    kWKLayoutModeViewSize = 0,
+    kWKLayoutModeFixedSize = 1,
+    kWKLayoutModeDynamicSizeComputedFromViewScale = 2,
+    kWKLayoutModeDynamicSizeComputedFromMinimumDocumentSize = 4
 };
 typedef uint32_t WKLayoutMode;
 
index 984ea76..9eef96f 100644 (file)
@@ -95,8 +95,6 @@
 @property (nonatomic, setter=_setLayoutMode:) WKLayoutMode _layoutMode;
 // For use with _layoutMode = kWKLayoutModeFixedSize:
 @property (nonatomic, setter=_setFixedLayoutSize:) CGSize _fixedLayoutSize;
-// For use with _layoutMode = kWKLayoutModeDynamicSizeWithMinimumViewSize:
-@property (nonatomic, setter=_setMinimumViewSize:) CGSize _minimumViewSize;
 
 @property (nonatomic, setter=_setViewScale:) CGFloat _viewScale;
 
index 0003b2a..1fc8937 100644 (file)
@@ -2506,8 +2506,6 @@ static inline WebKit::FindOptions toFindOptions(_WKFindOptions wkFindOptions)
         return _WKLayoutModeFixedSize;
     case kWKLayoutModeDynamicSizeComputedFromViewScale:
         return _WKLayoutModeDynamicSizeComputedFromViewScale;
-    case kWKLayoutModeDynamicSizeWithMinimumViewSize:
-        return _WKLayoutModeDynamicSizeWithMinimumViewSize;
     case kWKLayoutModeDynamicSizeComputedFromMinimumDocumentSize:
         return _WKLayoutModeDynamicSizeComputedFromMinimumDocumentSize;
     case kWKLayoutModeViewSize:
@@ -2530,9 +2528,6 @@ static inline WebKit::FindOptions toFindOptions(_WKFindOptions wkFindOptions)
     case _WKLayoutModeDynamicSizeComputedFromViewScale:
         wkViewLayoutMode = kWKLayoutModeDynamicSizeComputedFromViewScale;
         break;
-    case _WKLayoutModeDynamicSizeWithMinimumViewSize:
-        wkViewLayoutMode = kWKLayoutModeDynamicSizeWithMinimumViewSize;
-        break;
     case _WKLayoutModeDynamicSizeComputedFromMinimumDocumentSize:
         wkViewLayoutMode = kWKLayoutModeDynamicSizeComputedFromMinimumDocumentSize;
         break;
@@ -2574,22 +2569,6 @@ static inline WebKit::FindOptions toFindOptions(_WKFindOptions wkFindOptions)
 #endif
 }
 
-- (void)_setMinimumViewSize:(CGSize)minimumViewSize
-{
-#if PLATFORM(MAC)
-    [_wkView _setMinimumViewSize:minimumViewSize];
-#endif
-}
-
-- (CGSize)_minimumViewSize
-{
-#if PLATFORM(MAC)
-    return [_wkView _minimumViewSize];
-#else
-    return CGSizeZero;
-#endif
-}
-
 #pragma mark scrollperf methods
 
 - (void)_setScrollPerformanceDataCollectionEnabled:(BOOL)enabled
index a1edf8b..13dec4c 100644 (file)
@@ -99,8 +99,6 @@ WK_EXTERN NSString * const _WKShouldOpenExternalURLsKey WK_AVAILABLE(WK_MAC_TBA,
 @property (nonatomic, setter=_setLayoutMode:) _WKLayoutMode _layoutMode;
 // For use with _layoutMode = _WKLayoutModeFixedSize:
 @property (nonatomic, setter=_setFixedLayoutSize:) CGSize _fixedLayoutSize;
-// For use with _layoutMode = _WKLayoutModeDynamicSizeWithMinimumViewSize:
-@property (nonatomic, setter=_setMinimumViewSize:) CGSize _minimumViewSize;
 
 @property (nonatomic, setter=_setViewScale:) CGFloat _viewScale;
 
index 6d18e54..92a8a67 100644 (file)
 #if WK_API_ENABLED
 
 typedef NS_ENUM(NSUInteger, _WKLayoutMode) {
-    _WKLayoutModeViewSize,
-    _WKLayoutModeFixedSize,
+    _WKLayoutModeViewSize = 0,
+    _WKLayoutModeFixedSize = 1,
 
     // Lay out the view with its frame scaled by the inverse viewScale.
-    _WKLayoutModeDynamicSizeComputedFromViewScale,
-
-    // Lay out the view at a heuristically-determined size based on the minimum view size.
-    _WKLayoutModeDynamicSizeWithMinimumViewSize,
+    _WKLayoutModeDynamicSizeComputedFromViewScale = 2,
 
     // Lay out the view at a heuristically-determined size based on the minimum size of the document.
-    _WKLayoutModeDynamicSizeComputedFromMinimumDocumentSize,
+    _WKLayoutModeDynamicSizeComputedFromMinimumDocumentSize = 4,
 
 } WK_ENUM_AVAILABLE(WK_MAC_TBA, WK_IOS_TBA);
 
index da1e5fd..68ec374 100644 (file)
@@ -267,7 +267,6 @@ struct WKViewInterpretKeyEventsParameters {
     RetainPtr<WKViewLayoutStrategy> _layoutStrategy;
     WKLayoutMode _lastRequestedLayoutMode;
     float _lastRequestedViewScale;
-    CGSize _minimumViewSize;
 
     RetainPtr<CALayer> _rootLayer;
 
@@ -4390,17 +4389,6 @@ static NSString *pathWithUniqueFilenameForPath(NSString *path)
     [_data->_layoutStrategy didChangeViewScale];
 }
 
-- (void)_setMinimumViewSize:(CGSize)minimumViewSize
-{
-    _data->_minimumViewSize = minimumViewSize;
-    [_data->_layoutStrategy didChangeMinimumViewSize];
-}
-
-- (CGSize)_minimumViewSize
-{
-    return _data->_minimumViewSize;
-}
-
 - (void)_dispatchSetTopContentInset
 {
     if (!_data->_didScheduleSetTopContentInset)
index 8d39fac..e041d93 100644 (file)
@@ -2275,22 +2275,6 @@ void WebPageProxy::scaleView(double scale)
     m_process->send(Messages::WebPage::ScaleView(scale), m_pageID);
 }
 
-#if PLATFORM(COCOA)
-void WebPageProxy::scaleViewAndUpdateGeometryFenced(double scale, IntSize viewSize, std::function<void (const MachSendRight&, CallbackBase::Error)> callback)
-{
-    if (!isValid()) {
-        callback(MachSendRight(), CallbackBase::Error::OwnerWasInvalidated);
-        return;
-    }
-
-    m_viewScaleFactor = scale;
-    if (m_drawingArea)
-        m_drawingArea->willSendUpdateGeometry();
-    uint64_t callbackID = m_callbacks.put(WTF::move(callback), m_process->throttler().backgroundActivityToken());
-    m_process->send(Messages::WebPage::ScaleViewAndUpdateGeometryFenced(scale, viewSize, callbackID), m_pageID);
-}
-#endif
-
 void WebPageProxy::setIntrinsicDeviceScaleFactor(float scaleFactor)
 {
     if (m_intrinsicDeviceScaleFactor == scaleFactor)
index fb6445c..7a574d9 100644 (file)
@@ -642,9 +642,6 @@ public:
     double pageScaleFactor() const;
     double viewScaleFactor() const { return m_viewScaleFactor; }
     void scaleView(double scale);
-#if PLATFORM(COCOA)
-    void scaleViewAndUpdateGeometryFenced(double scale, WebCore::IntSize viewSize, std::function<void (const WebCore::MachSendRight&, CallbackBase::Error)>);
-#endif
     void setShouldScaleViewToFitDocument(bool);
     
     bool userContentExtensionsEnabled() { return m_userContentExtensionsEnabled; }
index e99d9fe..7b32b26 100644 (file)
@@ -54,7 +54,6 @@ class WebPageProxy;
 - (BOOL)frameSizeUpdatesDisabled;
 
 - (void)didChangeViewScale;
-- (void)didChangeMinimumViewSize;
 - (void)willStartLiveResize;
 - (void)didEndLiveResize;
 - (void)didChangeFrameSize;
index 09a45c6..49eea6e 100644 (file)
@@ -45,13 +45,6 @@ using namespace WebKit;
 @interface WKViewDynamicSizeComputedFromViewScaleLayoutStrategy : WKViewLayoutStrategy
 @end
 
-@interface WKViewDynamicSizeWithMinimumViewSizeLayoutStrategy : WKViewLayoutStrategy {
-    BOOL _isWaitingForCommit;
-    BOOL _hasPendingLayout;
-    CGFloat _lastCommittedViewScale;
-}
-@end
-
 @interface WKViewDynamicSizeComputedFromMinimumDocumentSizeLayoutStrategy : WKViewLayoutStrategy
 @end
 
@@ -68,9 +61,6 @@ using namespace WebKit;
     case kWKLayoutModeDynamicSizeComputedFromViewScale:
         strategy = [[WKViewDynamicSizeComputedFromViewScaleLayoutStrategy alloc] initWithPage:page view:wkView mode:mode];
         break;
-    case kWKLayoutModeDynamicSizeWithMinimumViewSize:
-        strategy = [[WKViewDynamicSizeWithMinimumViewSizeLayoutStrategy alloc] initWithPage:page view:wkView mode:mode];
-        break;
     case kWKLayoutModeDynamicSizeComputedFromMinimumDocumentSize:
         strategy = [[WKViewDynamicSizeComputedFromMinimumDocumentSizeLayoutStrategy alloc] initWithPage:page view:wkView mode:mode];
         break;
@@ -137,10 +127,6 @@ using namespace WebKit;
 {
 }
 
-- (void)didChangeMinimumViewSize
-{
-}
-
 - (void)willStartLiveResize
 {
 }
@@ -244,142 +230,6 @@ using namespace WebKit;
 
 @end
 
-@implementation WKViewDynamicSizeWithMinimumViewSizeLayoutStrategy
-
-- (instancetype)initWithPage:(WebPageProxy&)page view:(WKView *)wkView mode:(WKLayoutMode)mode
-{
-    self = [super initWithPage:page view:wkView mode:mode];
-
-    if (!self)
-        return nil;
-
-    page.setUseFixedLayout(true);
-    _lastCommittedViewScale = _page->viewScaleFactor();
-
-    return self;
-}
-
-- (void)_updateTransientScale:(CGFloat)scale
-{
-    float topContentInset = _page->topContentInset();
-
-    CGFloat relativeScale = scale / _lastCommittedViewScale;
-
-    CATransform3D transform = CATransform3DMakeTranslation(0, topContentInset - (topContentInset * relativeScale), 0);
-    transform = CATransform3DScale(transform, relativeScale, relativeScale, 1);
-
-    _wkView._rootLayer.transform = transform;
-}
-
-- (void)updateLayout
-{
-    _hasPendingLayout = NO;
-
-    CGFloat scale = 1;
-
-    CGFloat minimumViewWidth = _wkView._minimumViewSize.width;
-    CGFloat minimumViewHeight = _wkView._minimumViewSize.height;
-
-    CGFloat fixedLayoutWidth = _wkView.frame.size.width;
-    CGFloat fixedLayoutHeight = _wkView.frame.size.height;
-
-    if (NSIsEmptyRect(_wkView.frame))
-        return;
-
-    if (_wkView.frame.size.width < minimumViewWidth) {
-        scale = _wkView.frame.size.width / minimumViewWidth;
-        fixedLayoutWidth = minimumViewWidth;
-    }
-
-    if (_wkView.frame.size.height < minimumViewHeight) {
-        scale = std::min(_wkView.frame.size.height / minimumViewHeight, scale);
-        fixedLayoutWidth = minimumViewHeight;
-    }
-
-    _page->setFixedLayoutSize(IntSize(fixedLayoutWidth, fixedLayoutHeight));
-
-    [self _updateTransientScale:scale];
-
-    if (_isWaitingForCommit) {
-        _hasPendingLayout = YES;
-        return;
-    }
-
-    if ([_wkView inLiveResize] && _lastCommittedViewScale == 1 && scale == 1 && _frameSizeUpdatesDisabledCount == 1) {
-        // Send frame size updates if we're the only ones disabling them,
-        // if we're not scaling down. That way, everything will behave like a normal
-        // resize except in the critical section.
-        if (_wkView.shouldClipToVisibleRect)
-            [_wkView _updateViewExposedRect];
-        [_wkView _setDrawingAreaSize:[_wkView frame].size];
-        return;
-    }
-
-    if (_lastCommittedViewScale == scale)
-        return;
-
-    _isWaitingForCommit = YES;
-
-#if PLATFORM(IOS) || __MAC_OS_X_VERSION_MIN_REQUIRED >= 101000
-    RetainPtr<CAContext> context = [_wkView.layer context];
-    RetainPtr<WKViewDynamicSizeWithMinimumViewSizeLayoutStrategy> retainedSelf = self;
-    _page->scaleViewAndUpdateGeometryFenced(scale, IntSize(_wkView.frame.size), [retainedSelf, context, scale] (const WebCore::MachSendRight& fencePort, CallbackBase::Error error) {
-        if (error != CallbackBase::Error::None)
-            return;
-
-        [context setFencePort:fencePort.sendRight() commitHandler:[retainedSelf, scale] {
-            WKViewDynamicSizeWithMinimumViewSizeLayoutStrategy *layoutStrategy = retainedSelf.get();
-            layoutStrategy->_lastCommittedViewScale = scale;
-            [layoutStrategy _updateTransientScale:scale];
-            layoutStrategy->_isWaitingForCommit = NO;
-
-            if (layoutStrategy->_hasPendingLayout)
-                [layoutStrategy updateLayout];
-        }];
-    });
-#else
-    _page->scaleView(scale);
-    _wkView._rootLayer.transform = CATransform3DIdentity;
-#endif
-}
-
-- (void)didChangeMinimumViewSize
-{
-    [super didChangeMinimumViewSize];
-
-    [self updateLayout];
-}
-
-- (void)willStartLiveResize
-{
-    [super willStartLiveResize];
-
-    [_wkView disableFrameSizeUpdates];
-}
-
-- (void)didEndLiveResize
-{
-    [super didEndLiveResize];
-
-    [self updateLayout];
-    [_wkView enableFrameSizeUpdates];
-}
-
-- (void)didChangeFrameSize
-{
-    [super didChangeFrameSize];
-
-    [self updateLayout];
-}
-
-- (void)willChangeLayoutStrategy
-{
-    _wkView._rootLayer.transform = CATransform3DIdentity;
-    _page->scaleView(1);
-}
-
-@end
-
 @implementation WKViewDynamicSizeComputedFromMinimumDocumentSizeLayoutStrategy
 
 - (instancetype)initWithPage:(WebPageProxy&)page view:(WKView *)wkView mode:(WKLayoutMode)mode
index 3ad1917..44aec02 100644 (file)
@@ -132,8 +132,6 @@ public:
 #if PLATFORM(COCOA)
     // Used by TiledCoreAnimationDrawingArea.
     virtual void updateGeometry(const WebCore::IntSize& viewSize, const WebCore::IntSize& layerPosition, bool flushSynchronously, const WebCore::MachSendRight& fencePort) { }
-
-    virtual void replyWithFenceAfterNextFlush(uint64_t callbackID) { ASSERT_NOT_REACHED(); }
 #endif
 
 protected:
index 0d7b9df..12ff445 100644 (file)
@@ -1492,15 +1492,6 @@ void WebPage::scaleView(double scale)
     scalePage(pageScale, scrollPositionAtNewScale);
 }
 
-#if PLATFORM(COCOA)
-void WebPage::scaleViewAndUpdateGeometryFenced(double scale, IntSize viewSize, uint64_t callbackID)
-{
-    scaleView(scale);
-    m_drawingArea->updateGeometry(viewSize, IntSize(), false, MachSendRight());
-    m_drawingArea->replyWithFenceAfterNextFlush(callbackID);
-}
-#endif
-
 void WebPage::setDeviceScaleFactor(float scaleFactor)
 {
     if (scaleFactor == m_page->deviceScaleFactor())
index 1e2f61a..436244c 100644 (file)
@@ -370,9 +370,6 @@ public:
     double totalScaleFactor() const;
     double viewScaleFactor() const;
     void scaleView(double scale);
-#if PLATFORM(COCOA)
-    void scaleViewAndUpdateGeometryFenced(double scale, WebCore::IntSize viewSize, uint64_t callbackID);
-#endif
 
     void setUseFixedLayout(bool);
     bool useFixedLayout() const { return m_useFixedLayout; }
index a647180..49ef79c 100644 (file)
@@ -198,9 +198,6 @@ messages -> WebPage LegacyReceiver {
     ScalePage(double scale, WebCore::IntPoint origin)
     ScalePageInViewCoordinates(double scale, WebCore::IntPoint centerInViewCoordinates)
     ScaleView(double scale)
-#if PLATFORM(COCOA)
-    ScaleViewAndUpdateGeometryFenced(double scale, WebCore::IntSize viewSize, uint64_t callbackID)
-#endif
 
     SetUseFixedLayout(bool fixed)
     SetFixedLayoutSize(WebCore::IntSize size)
index 0abee23..174f59d 100644 (file)
@@ -86,8 +86,6 @@ private:
 
     virtual void attachViewOverlayGraphicsLayer(WebCore::Frame*, WebCore::GraphicsLayer*) override;
 
-    virtual void replyWithFenceAfterNextFlush(uint64_t callbackID) override;
-
     // WebCore::LayerFlushSchedulerClient
     virtual bool flushLayers() override;
 
@@ -152,7 +150,6 @@ private:
 
     WebCore::GraphicsLayer* m_viewOverlayRootLayer;
 
-    Vector<uint64_t> m_fenceCallbacksForAfterNextFlush;
     bool m_shouldScaleViewToFitDocument { false };
     bool m_isScalingViewToFitDocument { false };
     WebCore::IntSize m_lastViewSizeForScaleToFit;
index bdeb365..9d1a9be 100644 (file)
@@ -440,16 +440,6 @@ bool TiledCoreAnimationDrawingArea::flushLayers()
         if (m_transientZoomScale != 1)
             applyTransientZoomToLayers(m_transientZoomScale, m_transientZoomOrigin);
 
-        if (!m_fenceCallbacksForAfterNextFlush.isEmpty()) {
-            MachSendRight fencePort = m_layerHostingContext->createFencePort();
-
-            for (auto callbackID : m_fenceCallbacksForAfterNextFlush)
-                m_webPage.send(Messages::WebPageProxy::MachSendRightCallback(fencePort, callbackID));
-            m_fenceCallbacksForAfterNextFlush.clear();
-
-            m_layerHostingContext->setFencePort(fencePort.sendRight());
-        }
-
         return returnValue;
     }
 }
@@ -874,11 +864,6 @@ void TiledCoreAnimationDrawingArea::addFence(const MachSendRight& fencePort)
     m_layerHostingContext->setFencePort(fencePort.sendRight());
 }
 
-void TiledCoreAnimationDrawingArea::replyWithFenceAfterNextFlush(uint64_t callbackID)
-{
-    m_fenceCallbacksForAfterNextFlush.append(callbackID);
-}
-
 } // namespace WebKit
 
 #endif // !PLATFORM(IOS)