build-fix for the no-layers config
Change-Id: I4994cb5dc61cb845db76060fbd7680f6f5f9ab88
diff --git a/WebKit/android/nav/WebView.cpp b/WebKit/android/nav/WebView.cpp
index a397f57..2c6b538 100644
--- a/WebKit/android/nav/WebView.cpp
+++ b/WebKit/android/nav/WebView.cpp
@@ -292,10 +292,12 @@
return;
SkRect visible;
calcOurContentVisibleRect(&visible);
+#if USE(ACCELERATED_COMPOSITING)
if (m_rootLayer) {
m_rootLayer->updatePositions(visible);
visible = m_rootLayer->subtractLayers(visible);
}
+#endif
int dx = 0;
int left = rect.x();
int right = rect.right();
@@ -1799,11 +1801,13 @@
// this will playback the picture into the canvas, which will
// spew its contents to the dumper
view->getWebViewCore()->drawContent(&canvas, 0);
+#if USE(ACCELERATED_COMPOSITING)
if (true) {
LayerAndroid* rootLayer = view->rootLayer();
if (rootLayer)
rootLayer->draw(&canvas);
}
+#endif
// we're done with the file now
fwrite("\n", 1, 1, file);
fclose(file);