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/LineBoxListPainter.h" | 6 #include "core/paint/LineBoxListPainter.h" |
7 | 7 |
8 #include "core/paint/DrawingRecorder.h" | 8 #include "core/paint/DrawingRecorder.h" |
9 #include "core/paint/InlinePainter.h" | 9 #include "core/paint/InlinePainter.h" |
10 #include "core/rendering/InlineFlowBox.h" | 10 #include "core/rendering/InlineFlowBox.h" |
(...skipping 29 matching lines...) Expand all Loading... |
40 // them. Note that boxes can easily overlap, so we can't make any assumption
s | 40 // them. Note that boxes can easily overlap, so we can't make any assumption
s |
41 // based off positions of our first line box or our last line box. | 41 // based off positions of our first line box or our last line box. |
42 for (InlineFlowBox* curr = m_renderLineBoxList.firstLineBox(); curr; curr =
curr->nextLineBox()) { | 42 for (InlineFlowBox* curr = m_renderLineBoxList.firstLineBox(); curr; curr =
curr->nextLineBox()) { |
43 if (m_renderLineBoxList.lineIntersectsDirtyRect(renderer, curr, info, pa
intOffset)) { | 43 if (m_renderLineBoxList.lineIntersectsDirtyRect(renderer, curr, info, pa
intOffset)) { |
44 RootInlineBox& root = curr->root(); | 44 RootInlineBox& root = curr->root(); |
45 curr->paint(info, paintOffset, root.lineTop(), root.lineBottom()); | 45 curr->paint(info, paintOffset, root.lineTop(), root.lineBottom()); |
46 } | 46 } |
47 } | 47 } |
48 | 48 |
49 if (info.phase == PaintPhaseOutline || info.phase == PaintPhaseSelfOutline |
| info.phase == PaintPhaseChildOutlines) { | 49 if (info.phase == PaintPhaseOutline || info.phase == PaintPhaseSelfOutline |
| info.phase == PaintPhaseChildOutlines) { |
50 ListHashSet<RenderInline*>::iterator end = info.outlineObjects()->end(); | 50 for (RenderInline* flow : *info.outlineObjects()) |
51 for (ListHashSet<RenderInline*>::iterator it = info.outlineObjects()->be
gin(); it != end; ++it) { | |
52 RenderInline* flow = *it; | |
53 InlinePainter(*flow).paintOutline(info, paintOffset); | 51 InlinePainter(*flow).paintOutline(info, paintOffset); |
54 } | |
55 info.outlineObjects()->clear(); | 52 info.outlineObjects()->clear(); |
56 } | 53 } |
57 } | 54 } |
58 | 55 |
59 } // namespace blink | 56 } // namespace blink |
OLD | NEW |