summaryrefslogtreecommitdiffstats
path: root/cc/layer_tree_host.cc
diff options
context:
space:
mode:
authortedchoc@chromium.org <tedchoc@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2013-01-16 23:04:28 +0000
committertedchoc@chromium.org <tedchoc@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2013-01-16 23:04:28 +0000
commitfdc9eec417bb1eaf98485ab7e1285fcb432bcbcd (patch)
treef6af412a2679554c036d907d5be5295cedf856f4 /cc/layer_tree_host.cc
parent56998b0227da4ba92f8de3172005e7b405b6e657 (diff)
downloadchromium_src-fdc9eec417bb1eaf98485ab7e1285fcb432bcbcd.zip
chromium_src-fdc9eec417bb1eaf98485ab7e1285fcb432bcbcd.tar.gz
chromium_src-fdc9eec417bb1eaf98485ab7e1285fcb432bcbcd.tar.bz2
Remove top controls layer from cc/.
After danakj@ comment on the CL that added the top controls manager, I looked into layer positioning in the browser compositor to keep it in sync with the top controls UI widgets. This removes the need for the top controls layer and also gets rid of the need to pass an increased clip size to the layer tree host. Now the renderer compositor will make the webkit size and the browser compositor will be in charge of moving it around. BUG=161303 Review URL: https://chromiumcodereview.appspot.com/11967021 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@177250 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'cc/layer_tree_host.cc')
-rw-r--r--cc/layer_tree_host.cc21
1 files changed, 0 insertions, 21 deletions
diff --git a/cc/layer_tree_host.cc b/cc/layer_tree_host.cc
index 5e56eb8..e64cb3f 100644
--- a/cc/layer_tree_host.cc
+++ b/cc/layer_tree_host.cc
@@ -299,9 +299,6 @@ void LayerTreeHost::finishCommitOnImplThread(LayerTreeHostImpl* hostImpl)
hostImpl->setPageScaleFactorAndLimits(m_pageScaleFactor, m_minPageScaleFactor, m_maxPageScaleFactor);
hostImpl->setDebugState(m_debugState);
- if (m_settings.calculateTopControlsPosition && m_topControlsContentLayer && hostImpl->topControlsManager())
- hostImpl->topControlsManager()->set_content_layer_id(m_topControlsContentLayer->id());
-
m_commitNumber++;
}
@@ -440,8 +437,6 @@ void LayerTreeHost::setRootLayer(scoped_refptr<Layer> rootLayer)
if (m_hudLayer)
m_hudLayer->removeFromParent();
- if (m_topControlsContentLayer)
- m_topControlsContentLayer->removeFromParent();
setNeedsFullTreeSync();
}
@@ -538,22 +533,6 @@ void LayerTreeHost::updateLayers(ResourceUpdateQueue& queue, size_t memoryAlloca
if (memoryAllocationLimitBytes)
m_contentsTextureManager->setMaxMemoryLimitBytes(memoryAllocationLimitBytes);
- if (m_settings.calculateTopControlsPosition) {
- if (!m_topControlsContentLayer) {
- m_topControlsContentLayer = Layer::create();
- m_topControlsContentLayer->setIsDrawable(false);
- m_topControlsContentLayer->setDebugName("Top Controls Content");
- }
-
- // Insert a layer that allows the top controls manager to move around
- // the content without clobbering/being clobbered by other transforms.
- if (!LayerTreeHostCommon::findLayerInSubtree(m_rootLayer.get(), m_topControlsContentLayer->id())) {
- m_topControlsContentLayer->setLayerTreeHost(m_rootLayer->layerTreeHost());
- m_topControlsContentLayer->setChildren(m_rootLayer->children());
- m_rootLayer->addChild(m_topControlsContentLayer);
- }
- }
-
updateLayers(rootLayer(), queue);
}