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

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

Issue 1144903002: [SP] Delete GraphicsContextAnnotator. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 5 years, 7 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/InlinePainter.cpp ('k') | Source/core/paint/PartPainter.cpp » ('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/ListMarkerPainter.h" 6 #include "core/paint/ListMarkerPainter.h"
7 7
8 #include "core/layout/LayoutListItem.h" 8 #include "core/layout/LayoutListItem.h"
9 #include "core/layout/LayoutListMarker.h" 9 #include "core/layout/LayoutListMarker.h"
10 #include "core/layout/TextRunConstructor.h" 10 #include "core/layout/TextRunConstructor.h"
11 #include "core/paint/BlockPainter.h" 11 #include "core/paint/BlockPainter.h"
12 #include "core/paint/GraphicsContextAnnotator.h"
13 #include "core/paint/LayoutObjectDrawingRecorder.h" 12 #include "core/paint/LayoutObjectDrawingRecorder.h"
14 #include "core/paint/PaintInfo.h" 13 #include "core/paint/PaintInfo.h"
15 #include "platform/geometry/LayoutPoint.h" 14 #include "platform/geometry/LayoutPoint.h"
16 #include "platform/graphics/GraphicsContextStateSaver.h" 15 #include "platform/graphics/GraphicsContextStateSaver.h"
17 #include "wtf/unicode/CharacterNames.h" 16 #include "wtf/unicode/CharacterNames.h"
18 17
19 namespace blink { 18 namespace blink {
20 19
21 void ListMarkerPainter::paint(const PaintInfo& paintInfo, const LayoutPoint& pai ntOffset) 20 void ListMarkerPainter::paint(const PaintInfo& paintInfo, const LayoutPoint& pai ntOffset)
22 { 21 {
23 ANNOTATE_GRAPHICS_CONTEXT(paintInfo, &m_layoutListMarker);
24
25 if (paintInfo.phase != PaintPhaseForeground) 22 if (paintInfo.phase != PaintPhaseForeground)
26 return; 23 return;
27 24
28 if (m_layoutListMarker.style()->visibility() != VISIBLE) 25 if (m_layoutListMarker.style()->visibility() != VISIBLE)
29 return; 26 return;
30 27
31 LayoutPoint boxOrigin(paintOffset + m_layoutListMarker.location()); 28 LayoutPoint boxOrigin(paintOffset + m_layoutListMarker.location());
32 LayoutRect overflowRect(m_layoutListMarker.visualOverflowRect()); 29 LayoutRect overflowRect(m_layoutListMarker.visualOverflowRect());
33 overflowRect.moveBy(boxOrigin); 30 overflowRect.moveBy(boxOrigin);
34 31
(...skipping 176 matching lines...) Expand 10 before | Expand all | Expand 10 after
211 context->drawText(font, textRunPaintInfo, textOrigin); 208 context->drawText(font, textRunPaintInfo, textOrigin);
212 context->drawText(font, suffixRunInfo, textOrigin + IntSize(font.wid th(textRun), 0)); 209 context->drawText(font, suffixRunInfo, textOrigin + IntSize(font.wid th(textRun), 0));
213 } else { 210 } else {
214 context->drawText(font, suffixRunInfo, textOrigin); 211 context->drawText(font, suffixRunInfo, textOrigin);
215 context->drawText(font, textRunPaintInfo, textOrigin + IntSize(font. width(suffixRun), 0)); 212 context->drawText(font, textRunPaintInfo, textOrigin + IntSize(font. width(suffixRun), 0));
216 } 213 }
217 } 214 }
218 } 215 }
219 216
220 } // namespace blink 217 } // namespace blink
OLDNEW
« no previous file with comments | « Source/core/paint/InlinePainter.cpp ('k') | Source/core/paint/PartPainter.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698