| 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/PartPainter.h" | 5 #include "core/paint/PartPainter.h" |
| 6 | 6 |
| 7 #include "core/layout/LayoutPart.h" | 7 #include "core/layout/LayoutPart.h" |
| 8 #include "core/paint/BoxPainter.h" | 8 #include "core/paint/BoxPainter.h" |
| 9 #include "core/paint/LayoutObjectDrawingRecorder.h" | 9 #include "core/paint/LayoutObjectDrawingRecorder.h" |
| 10 #include "core/paint/ObjectPainter.h" | 10 #include "core/paint/ObjectPainter.h" |
| 11 #include "core/paint/PaintInfo.h" | 11 #include "core/paint/PaintInfo.h" |
| 12 #include "core/paint/PaintLayer.h" | 12 #include "core/paint/PaintLayer.h" |
| 13 #include "core/paint/ReplacedPainter.h" | 13 #include "core/paint/ReplacedPainter.h" |
| 14 #include "core/paint/RoundedInnerRectClipper.h" | 14 #include "core/paint/RoundedInnerRectClipper.h" |
| 15 #include "core/paint/ScrollableAreaPainter.h" | 15 #include "core/paint/ScrollableAreaPainter.h" |
| 16 #include "core/paint/TransformRecorder.h" | 16 #include "core/paint/TransformRecorder.h" |
| 17 #include "wtf/Optional.h" | 17 #include "platform/wtf/Optional.h" |
| 18 | 18 |
| 19 namespace blink { | 19 namespace blink { |
| 20 | 20 |
| 21 bool PartPainter::IsSelected() const { | 21 bool PartPainter::IsSelected() const { |
| 22 SelectionState s = layout_part_.GetSelectionState(); | 22 SelectionState s = layout_part_.GetSelectionState(); |
| 23 if (s == SelectionNone) | 23 if (s == SelectionNone) |
| 24 return false; | 24 return false; |
| 25 if (s == SelectionInside) | 25 if (s == SelectionInside) |
| 26 return true; | 26 return true; |
| 27 | 27 |
| (...skipping 106 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 134 TransformRecorder transform( | 134 TransformRecorder transform( |
| 135 paint_info.context, layout_part_, | 135 paint_info.context, layout_part_, |
| 136 AffineTransform::Translation(frame_view_base_paint_offset.Width(), | 136 AffineTransform::Translation(frame_view_base_paint_offset.Width(), |
| 137 frame_view_base_paint_offset.Height())); | 137 frame_view_base_paint_offset.Height())); |
| 138 CullRect adjusted_cull_rect(paint_info.GetCullRect(), | 138 CullRect adjusted_cull_rect(paint_info.GetCullRect(), |
| 139 -frame_view_base_paint_offset); | 139 -frame_view_base_paint_offset); |
| 140 frame_view_base->Paint(paint_info.context, adjusted_cull_rect); | 140 frame_view_base->Paint(paint_info.context, adjusted_cull_rect); |
| 141 } | 141 } |
| 142 | 142 |
| 143 } // namespace blink | 143 } // namespace blink |
| OLD | NEW |