OLD | NEW |
1 // Copyright 2011 The Chromium Authors. All rights reserved. | 1 // Copyright 2011 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "cc/layer_tree_host_impl.h" | 5 #include "cc/layer_tree_host_impl.h" |
6 | 6 |
7 #include <algorithm> | 7 #include <algorithm> |
8 | 8 |
9 #include "base/basictypes.h" | 9 #include "base/basictypes.h" |
10 #include "base/debug/trace_event.h" | 10 #include "base/debug/trace_event.h" |
(...skipping 363 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
374 { | 374 { |
375 DCHECK(renderSurfaceLayerList.empty()); | 375 DCHECK(renderSurfaceLayerList.empty()); |
376 DCHECK(m_rootLayerImpl); | 376 DCHECK(m_rootLayerImpl); |
377 DCHECK(m_renderer); // For maxTextureSize. | 377 DCHECK(m_renderer); // For maxTextureSize. |
378 | 378 |
379 { | 379 { |
380 updateRootScrollLayerImplTransform(); | 380 updateRootScrollLayerImplTransform(); |
381 | 381 |
382 TRACE_EVENT0("cc", "LayerTreeHostImpl::calcDrawEtc"); | 382 TRACE_EVENT0("cc", "LayerTreeHostImpl::calcDrawEtc"); |
383 float pageScaleFactor = m_pinchZoomViewport.pageScaleFactor(); | 383 float pageScaleFactor = m_pinchZoomViewport.pageScaleFactor(); |
384 LayerTreeHostCommon::calculateDrawTransforms(m_rootLayerImpl.get(), devi
ceViewportSize(), m_deviceScaleFactor, pageScaleFactor, &m_layerSorter, renderer
Capabilities().maxTextureSize, renderSurfaceLayerList); | 384 LayerTreeHostCommon::calculateDrawProperties(m_rootLayerImpl.get(), devi
ceViewportSize(), m_deviceScaleFactor, pageScaleFactor, &m_layerSorter, renderer
Capabilities().maxTextureSize, renderSurfaceLayerList); |
385 | 385 |
386 trackDamageForAllSurfaces(m_rootLayerImpl.get(), renderSurfaceLayerList)
; | 386 trackDamageForAllSurfaces(m_rootLayerImpl.get(), renderSurfaceLayerList)
; |
387 } | 387 } |
388 } | 388 } |
389 | 389 |
390 void LayerTreeHostImpl::FrameData::appendRenderPass(scoped_ptr<RenderPass> rende
rPass) | 390 void LayerTreeHostImpl::FrameData::appendRenderPass(scoped_ptr<RenderPass> rende
rPass) |
391 { | 391 { |
392 RenderPass* pass = renderPass.get(); | 392 RenderPass* pass = renderPass.get(); |
393 renderPasses.push_back(pass); | 393 renderPasses.push_back(pass); |
394 renderPassesById.set(pass->id, renderPass.Pass()); | 394 renderPassesById.set(pass->id, renderPass.Pass()); |
(...skipping 1237 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1632 ScrollbarAnimationController* scrollbarController = layer->scrollbarAnimatio
nController(); | 1632 ScrollbarAnimationController* scrollbarController = layer->scrollbarAnimatio
nController(); |
1633 double monotonicTime = (time - base::TimeTicks()).InSecondsF(); | 1633 double monotonicTime = (time - base::TimeTicks()).InSecondsF(); |
1634 if (scrollbarController && scrollbarController->animate(monotonicTime)) | 1634 if (scrollbarController && scrollbarController->animate(monotonicTime)) |
1635 m_client->setNeedsRedrawOnImplThread(); | 1635 m_client->setNeedsRedrawOnImplThread(); |
1636 | 1636 |
1637 for (size_t i = 0; i < layer->children().size(); ++i) | 1637 for (size_t i = 0; i < layer->children().size(); ++i) |
1638 animateScrollbarsRecursive(layer->children()[i], time); | 1638 animateScrollbarsRecursive(layer->children()[i], time); |
1639 } | 1639 } |
1640 | 1640 |
1641 } // namespace cc | 1641 } // namespace cc |
OLD | NEW |