Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(110)

Side by Side Diff: Source/core/paint/InlinePainter.cpp

Issue 585943004: Move painting code from RenderLineBoxList to LineBoxListPainter. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Merged. Created 6 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « Source/core/paint/BlockPainter.cpp ('k') | Source/core/paint/LineBoxListPainter.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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/InlinePainter.h" 6 #include "core/paint/InlinePainter.h"
7 7
8 #include "core/paint/BoxPainter.h" 8 #include "core/paint/BoxPainter.h"
9 #include "core/paint/LineBoxListPainter.h"
9 #include "core/paint/ObjectPainter.h" 10 #include "core/paint/ObjectPainter.h"
10 #include "core/rendering/GraphicsContextAnnotator.h" 11 #include "core/rendering/GraphicsContextAnnotator.h"
11 #include "core/rendering/PaintInfo.h" 12 #include "core/rendering/PaintInfo.h"
12 #include "core/rendering/RenderInline.h" 13 #include "core/rendering/RenderInline.h"
13 #include "core/rendering/RenderTheme.h" 14 #include "core/rendering/RenderTheme.h"
14 #include "core/rendering/RootInlineBox.h" 15 #include "core/rendering/RootInlineBox.h"
15 #include "platform/geometry/LayoutPoint.h" 16 #include "platform/geometry/LayoutPoint.h"
16 17
17 namespace blink { 18 namespace blink {
18 19
19 void InlinePainter::paint(PaintInfo& paintInfo, const LayoutPoint& paintOffset) 20 void InlinePainter::paint(PaintInfo& paintInfo, const LayoutPoint& paintOffset)
20 { 21 {
21 ANNOTATE_GRAPHICS_CONTEXT(paintInfo, &m_renderInline); 22 ANNOTATE_GRAPHICS_CONTEXT(paintInfo, &m_renderInline);
22 m_renderInline.lineBoxes()->paint(&m_renderInline, paintInfo, paintOffset); 23 LineBoxListPainter(*m_renderInline.lineBoxes()).paint(&m_renderInline, paint Info, paintOffset);
23 } 24 }
24 25
25 void InlinePainter::paintOutline(PaintInfo& paintInfo, const LayoutPoint& paintO ffset) 26 void InlinePainter::paintOutline(PaintInfo& paintInfo, const LayoutPoint& paintO ffset)
26 { 27 {
27 RenderStyle* styleToUse = m_renderInline.style(); 28 RenderStyle* styleToUse = m_renderInline.style();
28 if (!styleToUse->hasOutline()) 29 if (!styleToUse->hasOutline())
29 return; 30 return;
30 31
31 if (styleToUse->outlineStyleIsAuto()) { 32 if (styleToUse->outlineStyleIsAuto()) {
32 if (RenderTheme::theme().shouldDrawDefaultFocusRing(&m_renderInline)) { 33 if (RenderTheme::theme().shouldDrawDefaultFocusRing(&m_renderInline)) {
(...skipping 143 matching lines...) Expand 10 before | Expand all | Expand 10 after
176 pixelSnappedBox.maxX() + outlineWidth, 177 pixelSnappedBox.maxX() + outlineWidth,
177 pixelSnappedBox.maxY() + outlineWidth, 178 pixelSnappedBox.maxY() + outlineWidth,
178 BSBottom, outlineColor, outlineStyle, 179 BSBottom, outlineColor, outlineStyle,
179 outlineWidth, 180 outlineWidth,
180 outlineWidth, 181 outlineWidth,
181 antialias); 182 antialias);
182 } 183 }
183 } 184 }
184 185
185 } // namespace blink 186 } // namespace blink
OLDNEW
« no previous file with comments | « Source/core/paint/BlockPainter.cpp ('k') | Source/core/paint/LineBoxListPainter.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698