| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 "config.h" | 5 #include "config.h" |
| 6 #include "core/paint/DeprecatedPaintLayerPainter.h" | 6 #include "core/paint/DeprecatedPaintLayerPainter.h" |
| 7 | 7 |
| 8 #include "core/frame/Settings.h" | 8 #include "core/frame/Settings.h" |
| 9 #include "core/layout/ClipPathOperation.h" | 9 #include "core/layout/ClipPathOperation.h" |
| 10 #include "core/layout/LayoutBlock.h" | 10 #include "core/layout/LayoutBlock.h" |
| (...skipping 608 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 619 paintFragmentWithPhase(phase, fragment, context, fragment.foreground
Rect, localPaintingInfo, paintingRootForLayoutObject, paintFlags, clipState); | 619 paintFragmentWithPhase(phase, fragment, context, fragment.foreground
Rect, localPaintingInfo, paintingRootForLayoutObject, paintFlags, clipState); |
| 620 } | 620 } |
| 621 } | 621 } |
| 622 } | 622 } |
| 623 | 623 |
| 624 void DeprecatedPaintLayerPainter::paintOutlineForFragments(const DeprecatedPaint
LayerFragments& layerFragments, GraphicsContext* context, const DeprecatedPaintL
ayerPaintingInfo& localPaintingInfo, | 624 void DeprecatedPaintLayerPainter::paintOutlineForFragments(const DeprecatedPaint
LayerFragments& layerFragments, GraphicsContext* context, const DeprecatedPaintL
ayerPaintingInfo& localPaintingInfo, |
| 625 LayoutObject* paintingRootForLayoutObject, PaintLayerFlags paintFlags) | 625 LayoutObject* paintingRootForLayoutObject, PaintLayerFlags paintFlags) |
| 626 { | 626 { |
| 627 bool needsScope = layerFragments.size() > 1; | 627 bool needsScope = layerFragments.size() > 1; |
| 628 for (auto& fragment : layerFragments) { | 628 for (auto& fragment : layerFragments) { |
| 629 if (!fragment.outlineRect.isEmpty()) { | 629 if (!fragment.backgroundRect.isEmpty()) { |
| 630 Optional<ScopeRecorder> scopeRecorder; | 630 Optional<ScopeRecorder> scopeRecorder; |
| 631 if (needsScope) | 631 if (needsScope) |
| 632 scopeRecorder.emplace(*context); | 632 scopeRecorder.emplace(*context); |
| 633 paintFragmentWithPhase(PaintPhaseSelfOutline, fragment, context, fra
gment.outlineRect, localPaintingInfo, paintingRootForLayoutObject, paintFlags, H
asNotClipped); | 633 paintFragmentWithPhase(PaintPhaseSelfOutline, fragment, context, fra
gment.backgroundRect, localPaintingInfo, paintingRootForLayoutObject, paintFlags
, HasNotClipped); |
| 634 } | 634 } |
| 635 } | 635 } |
| 636 } | 636 } |
| 637 | 637 |
| 638 void DeprecatedPaintLayerPainter::paintMaskForFragments(const DeprecatedPaintLay
erFragments& layerFragments, GraphicsContext* context, const DeprecatedPaintLaye
rPaintingInfo& localPaintingInfo, | 638 void DeprecatedPaintLayerPainter::paintMaskForFragments(const DeprecatedPaintLay
erFragments& layerFragments, GraphicsContext* context, const DeprecatedPaintLaye
rPaintingInfo& localPaintingInfo, |
| 639 LayoutObject* paintingRootForLayoutObject, PaintLayerFlags paintFlags) | 639 LayoutObject* paintingRootForLayoutObject, PaintLayerFlags paintFlags) |
| 640 { | 640 { |
| 641 bool needsScope = layerFragments.size() > 1; | 641 bool needsScope = layerFragments.size() > 1; |
| 642 for (auto& fragment : layerFragments) { | 642 for (auto& fragment : layerFragments) { |
| 643 Optional<ScopeRecorder> scopeRecorder; | 643 Optional<ScopeRecorder> scopeRecorder; |
| (...skipping 20 matching lines...) Expand all Loading... |
| 664 if (!m_paintLayer.containsDirtyOverlayScrollbars()) | 664 if (!m_paintLayer.containsDirtyOverlayScrollbars()) |
| 665 return; | 665 return; |
| 666 | 666 |
| 667 DeprecatedPaintLayerPaintingInfo paintingInfo(&m_paintLayer, LayoutRect(encl
osingIntRect(damageRect)), paintFlags, LayoutSize(), paintingRoot); | 667 DeprecatedPaintLayerPaintingInfo paintingInfo(&m_paintLayer, LayoutRect(encl
osingIntRect(damageRect)), paintFlags, LayoutSize(), paintingRoot); |
| 668 paintLayer(context, paintingInfo, PaintLayerPaintingOverlayScrollbars); | 668 paintLayer(context, paintingInfo, PaintLayerPaintingOverlayScrollbars); |
| 669 | 669 |
| 670 m_paintLayer.setContainsDirtyOverlayScrollbars(false); | 670 m_paintLayer.setContainsDirtyOverlayScrollbars(false); |
| 671 } | 671 } |
| 672 | 672 |
| 673 } // namespace blink | 673 } // namespace blink |
| OLD | NEW |