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/TableSectionPainter.h" | 5 #include "core/paint/TableSectionPainter.h" |
6 | 6 |
7 #include "core/layout/LayoutTableCell.h" | 7 #include "core/layout/LayoutTableCell.h" |
8 #include "core/layout/LayoutTableCol.h" | 8 #include "core/layout/LayoutTableCol.h" |
9 #include "core/layout/LayoutTableRow.h" | 9 #include "core/layout/LayoutTableRow.h" |
10 #include "core/paint/BoxClipper.h" | 10 #include "core/paint/BoxClipper.h" |
(...skipping 277 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
288 void TableSectionPainter::paintBoxShadow(const PaintInfo& paintInfo, const Layou
tPoint& paintOffset, ShadowStyle shadowStyle) | 288 void TableSectionPainter::paintBoxShadow(const PaintInfo& paintInfo, const Layou
tPoint& paintOffset, ShadowStyle shadowStyle) |
289 { | 289 { |
290 DCHECK(shouldPaintSelfBlockBackground(paintInfo.phase)); | 290 DCHECK(shouldPaintSelfBlockBackground(paintInfo.phase)); |
291 if (!m_layoutTableSection.styleRef().boxShadow()) | 291 if (!m_layoutTableSection.styleRef().boxShadow()) |
292 return; | 292 return; |
293 | 293 |
294 DisplayItem::Type type = shadowStyle == Normal ? DisplayItem::TableSectionBo
xShadowNormal : DisplayItem::TableSectionBoxShadowInset; | 294 DisplayItem::Type type = shadowStyle == Normal ? DisplayItem::TableSectionBo
xShadowNormal : DisplayItem::TableSectionBoxShadowInset; |
295 if (LayoutObjectDrawingRecorder::useCachedDrawingIfPossible(paintInfo.contex
t, m_layoutTableSection, type)) | 295 if (LayoutObjectDrawingRecorder::useCachedDrawingIfPossible(paintInfo.contex
t, m_layoutTableSection, type)) |
296 return; | 296 return; |
297 | 297 |
298 LayoutRect bounds = BoxPainter(m_layoutTableSection).boundsForDrawingRecorde
r(paintOffset); | 298 LayoutRect bounds = BoxPainter(m_layoutTableSection).boundsForDrawingRecorde
r(paintInfo, paintOffset); |
299 LayoutObjectDrawingRecorder recorder(paintInfo.context, m_layoutTableSection
, type, bounds); | 299 LayoutObjectDrawingRecorder recorder(paintInfo.context, m_layoutTableSection
, type, bounds); |
300 BoxPainter::paintBoxShadow(paintInfo, LayoutRect(paintOffset, m_layoutTableS
ection.size()), m_layoutTableSection.styleRef(), shadowStyle); | 300 BoxPainter::paintBoxShadow(paintInfo, LayoutRect(paintOffset, m_layoutTableS
ection.size()), m_layoutTableSection.styleRef(), shadowStyle); |
301 } | 301 } |
302 | 302 |
303 } // namespace blink | 303 } // namespace blink |
OLD | NEW |