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 145 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
156 , m_cumulativeNumLayersDrawn(0) | 156 , m_cumulativeNumLayersDrawn(0) |
157 , m_cumulativeNumMissingTiles(0) | 157 , m_cumulativeNumMissingTiles(0) |
158 , m_lastSentMemoryVisibleBytes(0) | 158 , m_lastSentMemoryVisibleBytes(0) |
159 , m_lastSentMemoryVisibleAndNearbyBytes(0) | 159 , m_lastSentMemoryVisibleAndNearbyBytes(0) |
160 , m_lastSentMemoryUseBytes(0) | 160 , m_lastSentMemoryUseBytes(0) |
161 , m_animationRegistrar(AnimationRegistrar::create()) | 161 , m_animationRegistrar(AnimationRegistrar::create()) |
162 { | 162 { |
163 DCHECK(m_proxy->isImplThread()); | 163 DCHECK(m_proxy->isImplThread()); |
164 didVisibilityChange(this, m_visible); | 164 didVisibilityChange(this, m_visible); |
165 | 165 |
166 if (settings.calculateTopControlsPosition) | 166 if (settings.calculateTopControlsPosition) { |
167 m_topControlsManager = TopControlsManager::Create(this, settings.topCont
rolsHeight); | 167 m_topControlsManager = TopControlsManager::Create(this, |
| 168 settings.topControlsHe
ight, |
| 169 settings.topControlsSh
owThreshold, |
| 170 settings.topControlsHi
deThreshold); |
| 171 } |
168 | 172 |
169 setDebugState(settings.initialDebugState); | 173 setDebugState(settings.initialDebugState); |
170 | 174 |
171 // LTHI always has an active tree. | 175 // LTHI always has an active tree. |
172 m_activeTree = LayerTreeImpl::create(this); | 176 m_activeTree = LayerTreeImpl::create(this); |
173 } | 177 } |
174 | 178 |
175 LayerTreeHostImpl::~LayerTreeHostImpl() | 179 LayerTreeHostImpl::~LayerTreeHostImpl() |
176 { | 180 { |
177 DCHECK(m_proxy->isImplThread()); | 181 DCHECK(m_proxy->isImplThread()); |
(...skipping 1550 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1728 if (m_tileManager) | 1732 if (m_tileManager) |
1729 m_tileManager->SetRecordRenderingStats(m_debugState.recordRenderingStats
()); | 1733 m_tileManager->SetRecordRenderingStats(m_debugState.recordRenderingStats
()); |
1730 } | 1734 } |
1731 | 1735 |
1732 void LayerTreeHostImpl::savePaintTime(const base::TimeDelta& totalPaintTime) | 1736 void LayerTreeHostImpl::savePaintTime(const base::TimeDelta& totalPaintTime) |
1733 { | 1737 { |
1734 m_paintTimeCounter->SavePaintTime(totalPaintTime); | 1738 m_paintTimeCounter->SavePaintTime(totalPaintTime); |
1735 } | 1739 } |
1736 | 1740 |
1737 } // namespace cc | 1741 } // namespace cc |
OLD | NEW |