Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(702)

Unified Diff: third_party/WebKit/Source/platform/graphics/compositing/PaintArtifactCompositor.cpp

Issue 1705863002: [SPv2] Remove PaintArtifactCompositor::initializeIfNeeded. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/Source/platform/graphics/compositing/PaintArtifactCompositor.cpp
diff --git a/third_party/WebKit/Source/platform/graphics/compositing/PaintArtifactCompositor.cpp b/third_party/WebKit/Source/platform/graphics/compositing/PaintArtifactCompositor.cpp
index 763fa94c2fa17b45e8d36f0901becb77e7adb90e..6592c1a1350ec5712ef63ede8d17cd2e32654fcf 100644
--- a/third_party/WebKit/Source/platform/graphics/compositing/PaintArtifactCompositor.cpp
+++ b/third_party/WebKit/Source/platform/graphics/compositing/PaintArtifactCompositor.cpp
@@ -65,22 +65,16 @@ private:
PaintArtifactCompositor::PaintArtifactCompositor()
{
+ if (!RuntimeEnabledFeatures::slimmingPaintV2Enabled())
+ return;
+ m_rootLayer = cc::Layer::Create(cc::LayerSettings());
+ m_webLayer = adoptPtr(Platform::current()->compositorSupport()->createLayerFromCCLayer(m_rootLayer.get()));
}
PaintArtifactCompositor::~PaintArtifactCompositor()
{
}
-void PaintArtifactCompositor::initializeIfNeeded()
-{
- ASSERT(RuntimeEnabledFeatures::slimmingPaintV2Enabled());
- if (m_rootLayer)
- return;
-
- m_rootLayer = cc::Layer::Create(cc::LayerSettings());
- m_webLayer = adoptPtr(Platform::current()->compositorSupport()->createLayerFromCCLayer(m_rootLayer.get()));
-}
-
namespace {
static void appendDisplayItemToCcDisplayItemList(const DisplayItem& displayItem, cc::DisplayItemList* list)

Powered by Google App Engine
This is Rietveld 408576698