| 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_impl.h" | 5 #include "cc/layer_impl.h" |
| 6 | 6 |
| 7 #include "base/debug/trace_event.h" | 7 #include "base/debug/trace_event.h" |
| 8 #include "base/stringprintf.h" | 8 #include "base/stringprintf.h" |
| 9 #include "cc/debug_border_draw_quad.h" | 9 #include "cc/debug_border_draw_quad.h" |
| 10 #include "cc/debug_colors.h" | 10 #include "cc/debug_colors.h" |
| (...skipping 131 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 142 #ifndef NDEBUG | 142 #ifndef NDEBUG |
| 143 DCHECK(m_betweenWillDrawAndDidDraw); | 143 DCHECK(m_betweenWillDrawAndDidDraw); |
| 144 m_betweenWillDrawAndDidDraw = false; | 144 m_betweenWillDrawAndDidDraw = false; |
| 145 #endif | 145 #endif |
| 146 } | 146 } |
| 147 | 147 |
| 148 bool LayerImpl::showDebugBorders() const | 148 bool LayerImpl::showDebugBorders() const |
| 149 { | 149 { |
| 150 if (!m_layerTreeHostImpl) | 150 if (!m_layerTreeHostImpl) |
| 151 return false; | 151 return false; |
| 152 return m_layerTreeHostImpl->settings().showDebugBorders; | 152 return m_layerTreeHostImpl->debugState().showDebugBorders; |
| 153 } | 153 } |
| 154 | 154 |
| 155 void LayerImpl::getDebugBorderProperties(SkColor* color, float* width) const | 155 void LayerImpl::getDebugBorderProperties(SkColor* color, float* width) const |
| 156 { | 156 { |
| 157 if (m_drawsContent) { | 157 if (m_drawsContent) { |
| 158 *color = DebugColors::ContentLayerBorderColor(); | 158 *color = DebugColors::ContentLayerBorderColor(); |
| 159 *width = DebugColors::ContentLayerBorderWidth(m_layerTreeHostImpl); | 159 *width = DebugColors::ContentLayerBorderWidth(m_layerTreeHostImpl); |
| 160 return; | 160 return; |
| 161 } | 161 } |
| 162 | 162 |
| (...skipping 559 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 722 | 722 |
| 723 void LayerImpl::setVerticalScrollbarLayer(ScrollbarLayerImpl* scrollbarLayer) | 723 void LayerImpl::setVerticalScrollbarLayer(ScrollbarLayerImpl* scrollbarLayer) |
| 724 { | 724 { |
| 725 if (!m_scrollbarAnimationController) | 725 if (!m_scrollbarAnimationController) |
| 726 m_scrollbarAnimationController = ScrollbarAnimationController::create(th
is); | 726 m_scrollbarAnimationController = ScrollbarAnimationController::create(th
is); |
| 727 m_scrollbarAnimationController->setVerticalScrollbarLayer(scrollbarLayer); | 727 m_scrollbarAnimationController->setVerticalScrollbarLayer(scrollbarLayer); |
| 728 m_scrollbarAnimationController->updateScrollOffset(this); | 728 m_scrollbarAnimationController->updateScrollOffset(this); |
| 729 } | 729 } |
| 730 | 730 |
| 731 } // namespace cc | 731 } // namespace cc |
| OLD | NEW |