[iOS] Fix build of RenderLayerCompositor::registerAllViewportConstrainedLayers()
authorddkilzer@apple.com <ddkilzer@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Sun, 12 Jan 2014 04:56:31 +0000 (04:56 +0000)
committerddkilzer@apple.com <ddkilzer@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Sun, 12 Jan 2014 04:56:31 +0000 (04:56 +0000)
* rendering/RenderLayerCompositor.cpp:
(WebCore::RenderLayerCompositor::registerAllViewportConstrainedLayers):
Fix use of std::make_unique<>() and add an adoptPtr() call.

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

Source/WebCore/ChangeLog
Source/WebCore/rendering/RenderLayerCompositor.cpp

index f7e387fe6f11ae4d81bc025e31f27368ea57e89f..3d66a2d132c52cfb41248c29c688c032c9202172 100644 (file)
@@ -1,3 +1,11 @@
+2014-01-11  David Kilzer  <ddkilzer@apple.com>
+
+        [iOS] Fix build of RenderLayerCompositor::registerAllViewportConstrainedLayers()
+
+        * rendering/RenderLayerCompositor.cpp:
+        (WebCore::RenderLayerCompositor::registerAllViewportConstrainedLayers):
+        Fix use of std::make_unique<>() and add an adoptPtr() call.
+
 2014-01-11  Alexey Proskuryakov  <ap@apple.com>
 
         [Mac] [Windows] Stop scheduling network requests in WebCore
index e9cf230a990b28f4cb7f0f43a51f1b5a715332dc..7ae96e42df9c49d07845234e62ac85c8a20ab83d 100644 (file)
@@ -3500,16 +3500,16 @@ void RenderLayerCompositor::registerAllViewportConstrainedLayers()
 
         std::unique_ptr<ViewportConstraints> constraints;
         if (layer.renderer().isStickyPositioned()) {
-            constraints = std::make_unique<ViewportConstraints>(new StickyPositionViewportConstraints(computeStickyViewportConstraints(layer)));
+            constraints = std::make_unique<StickyPositionViewportConstraints>(computeStickyViewportConstraints(layer));
             const RenderLayer* enclosingTouchScrollableLayer = nullptr;
             if (isStickyInAcceleratedScrollingLayerOrViewport(layer, &enclosingTouchScrollableLayer) && enclosingTouchScrollableLayer) {
                 ASSERT(enclosingTouchScrollableLayer->isComposited());
                 stickyContainerMap.add(layer.backing()->graphicsLayer()->platformLayer(), enclosingTouchScrollableLayer->backing()->scrollingLayer()->platformLayer());
             }
         } else
-            constraints = std::make_unique<ViewportConstraints>(new FixedPositionViewportConstraints(computeFixedViewportConstraints(layer)));
+            constraints = std::make_unique<FixedPositionViewportConstraints>(computeFixedViewportConstraints(layer));
 
-        layerMap.add(layer.backing()->graphicsLayer()->platformLayer(), constraints.release());
+        layerMap.add(layer.backing()->graphicsLayer()->platformLayer(), adoptPtr(constraints.release()));
     }
     
     if (ChromeClient* client = this->chromeClient())