| Index: third_party/WebKit/Source/platform/testing/WebLayerTreeViewImplForTesting.cpp
|
| diff --git a/third_party/WebKit/Source/platform/testing/WebLayerTreeViewImplForTesting.cpp b/third_party/WebKit/Source/platform/testing/WebLayerTreeViewImplForTesting.cpp
|
| index 288bc5d1345ddbc2e680a90f05fe85fae53e0e85..42803967b72775865d970f308065a354bf7a0843 100644
|
| --- a/third_party/WebKit/Source/platform/testing/WebLayerTreeViewImplForTesting.cpp
|
| +++ b/third_party/WebKit/Source/platform/testing/WebLayerTreeViewImplForTesting.cpp
|
| @@ -18,13 +18,12 @@
|
| namespace blink {
|
|
|
| WebLayerTreeViewImplForTesting::WebLayerTreeViewImplForTesting()
|
| + : WebLayerTreeViewImplForTesting(defaultLayerTreeSettings())
|
| {
|
| - cc::LayerTreeSettings settings;
|
| -
|
| - // For web contents, layer transforms should scale up the contents of layers
|
| - // to keep content always crisp when possible.
|
| - settings.layer_transforms_should_scale_layer_contents = true;
|
| +}
|
|
|
| +WebLayerTreeViewImplForTesting::WebLayerTreeViewImplForTesting(const cc::LayerTreeSettings& settings)
|
| +{
|
| cc::LayerTreeHost::InitParams params;
|
| params.client = this;
|
| params.settings = &settings;
|
| @@ -36,6 +35,18 @@ WebLayerTreeViewImplForTesting::WebLayerTreeViewImplForTesting()
|
|
|
| WebLayerTreeViewImplForTesting::~WebLayerTreeViewImplForTesting() {}
|
|
|
| +// static
|
| +cc::LayerTreeSettings WebLayerTreeViewImplForTesting::defaultLayerTreeSettings()
|
| +{
|
| + cc::LayerTreeSettings settings;
|
| +
|
| + // For web contents, layer transforms should scale up the contents of layers
|
| + // to keep content always crisp when possible.
|
| + settings.layer_transforms_should_scale_layer_contents = true;
|
| +
|
| + return settings;
|
| +}
|
| +
|
| void WebLayerTreeViewImplForTesting::setRootLayer(const blink::WebLayer& root)
|
| {
|
| m_layerTreeHost->SetRootLayer(static_cast<const cc_blink::WebLayerImpl*>(&root)->layer());
|
|
|