Clean up some TiledCoreAnimationDrawingArea members
authorsimon.fraser@apple.com <simon.fraser@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 22 Mar 2019 04:22:05 +0000 (04:22 +0000)
committersimon.fraser@apple.com <simon.fraser@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 22 Mar 2019 04:22:05 +0000 (04:22 +0000)
https://bugs.webkit.org/show_bug.cgi?id=196124

Reviewed by Tim Horton.

The giant m_transform was unused.

Group the bools etc.

* WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.h:
* WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.mm:
(WebKit::TiledCoreAnimationDrawingArea::TiledCoreAnimationDrawingArea):
(WebKit::TiledCoreAnimationDrawingArea::setRootCompositingLayer):

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

Source/WebKit/ChangeLog
Source/WebKit/WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.h
Source/WebKit/WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.mm

index 4f3ef90..e202392 100644 (file)
@@ -1,3 +1,19 @@
+2019-03-21  Simon Fraser  <simon.fraser@apple.com>
+
+        Clean up some TiledCoreAnimationDrawingArea members
+        https://bugs.webkit.org/show_bug.cgi?id=196124
+
+        Reviewed by Tim Horton.
+
+        The giant m_transform was unused.
+        
+        Group the bools etc.
+
+        * WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.h:
+        * WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.mm:
+        (WebKit::TiledCoreAnimationDrawingArea::TiledCoreAnimationDrawingArea):
+        (WebKit::TiledCoreAnimationDrawingArea::setRootCompositingLayer):
+
 2019-03-21  Brady Eidson  <beidson@apple.com>
 
         Certain WebProcesses should opt-out of the freezer.
index 74661fd..58bda64 100644 (file)
@@ -136,28 +136,25 @@ private:
     void startLayerFlushThrottlingTimer();
     void layerFlushThrottlingTimerFired();
 
-    bool m_layerTreeStateIsFrozen;
-
     std::unique_ptr<LayerHostingContext> m_layerHostingContext;
 
     RetainPtr<CALayer> m_hostingLayer;
     RetainPtr<CALayer> m_rootLayer;
     RetainPtr<CALayer> m_debugInfoLayer;
-
     RetainPtr<CALayer> m_pendingRootLayer;
 
-    bool m_isPaintingSuspended;
-
     Optional<WebCore::FloatRect> m_viewExposedRect;
     Optional<WebCore::FloatRect> m_scrolledViewExposedRect;
 
+    WebCore::IntSize m_lastViewSizeForScaleToFit;
+    WebCore::IntSize m_lastDocumentSizeForScaleToFit;
+
     WebCore::IntSize m_lastSentIntrinsicContentSize;
-    bool m_inUpdateGeometry;
 
-    double m_transientZoomScale;
+    double m_transientZoomScale { 1 };
     WebCore::FloatPoint m_transientZoomOrigin;
 
-    WebCore::TransformationMatrix m_transform;
+    WebCore::Timer m_layerFlushThrottlingTimer;
 
     RunLoop::Timer<TiledCoreAnimationDrawingArea> m_sendDidUpdateActivityStateTimer;
     Vector<CallbackID> m_nextActivityStateChangeCallbackIDs;
@@ -165,21 +162,19 @@ private:
 
     RefPtr<WebCore::GraphicsLayer> m_viewOverlayRootLayer;
 
-    bool m_shouldScaleViewToFitDocument { false };
-    bool m_isScalingViewToFitDocument { false };
-    WebCore::IntSize m_lastViewSizeForScaleToFit;
-    WebCore::IntSize m_lastDocumentSizeForScaleToFit;
-
     OptionSet<WebCore::LayoutMilestone> m_pendingNewlyReachedLayoutMilestones;
     Vector<CallbackID> m_pendingCallbackIDs;
 
     std::unique_ptr<WebCore::RunLoopObserver> m_layerFlushRunLoopObserver;
 
+    bool m_isPaintingSuspended { false };
+    bool m_inUpdateGeometry { false };
+    bool m_layerTreeStateIsFrozen { false };
+    bool m_shouldScaleViewToFitDocument { false };
+    bool m_isScalingViewToFitDocument { false };
     bool m_isThrottlingLayerFlushes { false };
     bool m_isLayerFlushThrottlingTemporarilyDisabledForInteraction { false };
     bool m_needsSendEnterAcceleratedCompositingMode { true };
-
-    WebCore::Timer m_layerFlushThrottlingTimer;
 };
 
 } // namespace WebKit
index 6e06308..fe72854 100644 (file)
@@ -75,12 +75,9 @@ using namespace WebCore;
 
 TiledCoreAnimationDrawingArea::TiledCoreAnimationDrawingArea(WebPage& webPage, const WebPageCreationParameters& parameters)
     : DrawingArea(DrawingAreaTypeTiledCoreAnimation, parameters.drawingAreaIdentifier, webPage)
-    , m_layerTreeStateIsFrozen(false)
-    , m_isPaintingSuspended(!(parameters.activityState & ActivityState::IsVisible))
-    , m_transientZoomScale(1)
-    , m_sendDidUpdateActivityStateTimer(RunLoop::main(), this, &TiledCoreAnimationDrawingArea::didUpdateActivityStateTimerFired)
-    , m_viewOverlayRootLayer(nullptr)
     , m_layerFlushThrottlingTimer(*this, &TiledCoreAnimationDrawingArea::layerFlushThrottlingTimerFired)
+    , m_sendDidUpdateActivityStateTimer(RunLoop::main(), this, &TiledCoreAnimationDrawingArea::didUpdateActivityStateTimerFired)
+    , m_isPaintingSuspended(!(parameters.activityState & ActivityState::IsVisible))
 {
     m_webPage.corePage()->settings().setForceCompositingMode(true);
 
@@ -698,7 +695,6 @@ void TiledCoreAnimationDrawingArea::setRootCompositingLayer(CALayer *layer)
 
     bool hadRootLayer = !!m_rootLayer;
     m_rootLayer = layer;
-    [m_rootLayer setSublayerTransform:m_transform];
 
     updateRootLayers();