Chromium Code Reviews| 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 "core/paint/PaintLayerPainter.h" | 5 #include "core/paint/PaintLayerPainter.h" |
| 6 | 6 |
| 7 #include "core/frame/FrameView.h" | 7 #include "core/frame/FrameView.h" |
| 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 90 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 101 | 101 |
| 102 PaintLayerPainter::PaintResult PaintLayerPainter::paintLayerContentsAndReflectio n(GraphicsContext& context, const PaintLayerPaintingInfo& paintingInfo, PaintLay erFlags paintFlags, FragmentPolicy fragmentPolicy) | 102 PaintLayerPainter::PaintResult PaintLayerPainter::paintLayerContentsAndReflectio n(GraphicsContext& context, const PaintLayerPaintingInfo& paintingInfo, PaintLay erFlags paintFlags, FragmentPolicy fragmentPolicy) |
| 103 { | 103 { |
| 104 ASSERT(m_paintLayer.isSelfPaintingLayer() || m_paintLayer.hasSelfPaintingLay erDescendant()); | 104 ASSERT(m_paintLayer.isSelfPaintingLayer() || m_paintLayer.hasSelfPaintingLay erDescendant()); |
| 105 | 105 |
| 106 PaintLayerFlags localPaintFlags = paintFlags & ~(PaintLayerAppliedTransform) ; | 106 PaintLayerFlags localPaintFlags = paintFlags & ~(PaintLayerAppliedTransform) ; |
| 107 | 107 |
| 108 PaintResult result = FullyPainted; | 108 PaintResult result = FullyPainted; |
| 109 | 109 |
| 110 // Paint the reflection first if we have one. | 110 // Paint the reflection first if we have one. |
| 111 if (m_paintLayer.reflectionInfo()) { | 111 if (m_paintLayer.reflectionInfo() && !RuntimeEnabledFeatures::cssBoxReflectF ilterEnabled()) { |
|
Stephen White
2016/03/30 14:41:35
It seems fragile to have to check this flag in so
| |
| 112 ScopeRecorder scopeRecorder(context); | 112 ScopeRecorder scopeRecorder(context); |
| 113 if (m_paintLayer.reflectionInfo()->paint(context, paintingInfo, localPai ntFlags) == MayBeClippedByPaintDirtyRect) | 113 if (m_paintLayer.reflectionInfo()->paint(context, paintingInfo, localPai ntFlags) == MayBeClippedByPaintDirtyRect) |
| 114 result = MayBeClippedByPaintDirtyRect; | 114 result = MayBeClippedByPaintDirtyRect; |
| 115 } | 115 } |
| 116 | 116 |
| 117 localPaintFlags |= PaintLayerPaintingCompositingAllPhases; | 117 localPaintFlags |= PaintLayerPaintingCompositingAllPhases; |
| 118 if (paintLayerContents(context, paintingInfo, localPaintFlags, fragmentPolic y) == MayBeClippedByPaintDirtyRect) | 118 if (paintLayerContents(context, paintingInfo, localPaintFlags, fragmentPolic y) == MayBeClippedByPaintDirtyRect) |
| 119 result = MayBeClippedByPaintDirtyRect; | 119 result = MayBeClippedByPaintDirtyRect; |
| 120 | 120 |
| 121 return result; | 121 return result; |
| (...skipping 652 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 774 if (!m_paintLayer.containsDirtyOverlayScrollbars()) | 774 if (!m_paintLayer.containsDirtyOverlayScrollbars()) |
| 775 return; | 775 return; |
| 776 | 776 |
| 777 PaintLayerPaintingInfo paintingInfo(&m_paintLayer, LayoutRect(enclosingIntRe ct(damageRect)), paintFlags, LayoutSize()); | 777 PaintLayerPaintingInfo paintingInfo(&m_paintLayer, LayoutRect(enclosingIntRe ct(damageRect)), paintFlags, LayoutSize()); |
| 778 paintLayer(context, paintingInfo, PaintLayerPaintingOverlayScrollbars); | 778 paintLayer(context, paintingInfo, PaintLayerPaintingOverlayScrollbars); |
| 779 | 779 |
| 780 m_paintLayer.setContainsDirtyOverlayScrollbars(false); | 780 m_paintLayer.setContainsDirtyOverlayScrollbars(false); |
| 781 } | 781 } |
| 782 | 782 |
| 783 } // namespace blink | 783 } // namespace blink |
| OLD | NEW |