Index: content/test/web_layer_tree_view_impl_for_testing.cc |
diff --git a/content/test/web_layer_tree_view_impl_for_testing.cc b/content/test/web_layer_tree_view_impl_for_testing.cc |
index d29e68b802a5debab3797aba80121623736c23b3..4d2533a6fd7665c1eed6d4bf2ff7ffa894da414e 100644 |
--- a/content/test/web_layer_tree_view_impl_for_testing.cc |
+++ b/content/test/web_layer_tree_view_impl_for_testing.cc |
@@ -164,4 +164,24 @@ WebLayerTreeViewImplForTesting::OffscreenContextProvider() { |
OffscreenContextProviderForMainThread(); |
} |
+void WebLayerTreeViewImplForTesting::registerViewportLayers( |
+ const blink::WebLayer* pageScaleLayer, |
+ const blink::WebLayer* innerViewportScrollLayer, |
+ const blink::WebLayer* outerViewportScrollLayer) { |
+ layer_tree_host_->RegisterViewportLayers( |
+ static_cast<const WebLayerImpl*>(pageScaleLayer)->layer(), |
+ static_cast<const WebLayerImpl*>(innerViewportScrollLayer)->layer(), |
+ // The outer viewport layer will only exist when using pinch virtual |
+ // viewports. |
+ outerViewportScrollLayer |
+ ? static_cast<const WebLayerImpl*>(outerViewportScrollLayer)->layer() |
+ : NULL); |
+} |
+ |
+void WebLayerTreeViewImplForTesting::clearViewportLayers() { |
+ layer_tree_host_->RegisterViewportLayers(scoped_refptr<cc::Layer>(), |
+ scoped_refptr<cc::Layer>(), |
+ scoped_refptr<cc::Layer>()); |
+} |
+ |
} // namespace webkit |