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

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

Issue 899163003: Move rendering/RenderObject to layout/LayoutObject. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 5 years, 10 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
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2013 Google Inc. All rights reserved. 2 * Copyright (C) 2013 Google Inc. All rights reserved.
3 * Copyright (C) 2013 Samsung Electronics. All rights reserved. 3 * Copyright (C) 2013 Samsung Electronics. All rights reserved.
4 * 4 *
5 * Redistribution and use in source and binary forms, with or without 5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions are 6 * modification, are permitted provided that the following conditions are
7 * met: 7 * met:
8 * 8 *
9 * * Redistributions of source code must retain the above copyright 9 * * Redistributions of source code must retain the above copyright
10 * notice, this list of conditions and the following disclaimer. 10 * notice, this list of conditions and the following disclaimer.
(...skipping 15 matching lines...) Expand all
26 * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 26 * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
27 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 27 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
28 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 28 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
29 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 29 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
30 */ 30 */
31 31
32 #include "config.h" 32 #include "config.h"
33 #include "core/paint/GraphicsContextAnnotator.h" 33 #include "core/paint/GraphicsContextAnnotator.h"
34 34
35 #include "core/inspector/InspectorNodeIds.h" 35 #include "core/inspector/InspectorNodeIds.h"
36 #include "core/layout/LayoutObject.h"
36 #include "core/rendering/PaintInfo.h" 37 #include "core/rendering/PaintInfo.h"
37 #include "core/rendering/RenderObject.h"
38 #include "platform/graphics/GraphicsContextAnnotation.h" 38 #include "platform/graphics/GraphicsContextAnnotation.h"
39 #include "wtf/text/StringBuilder.h" 39 #include "wtf/text/StringBuilder.h"
40 40
41 namespace { 41 namespace {
42 42
43 const char AnnotationKeyRendererName[] = "RENDERER"; 43 const char AnnotationKeyRendererName[] = "RENDERER";
44 const char AnnotationKeyPaintPhase[] = "PHASE"; 44 const char AnnotationKeyPaintPhase[] = "PHASE";
45 const char AnnotationKeyElementId[] = "ID"; 45 const char AnnotationKeyElementId[] = "ID";
46 const char AnnotationKeyElementClass[] = "CLASS"; 46 const char AnnotationKeyElementClass[] = "CLASS";
47 const char AnnotationKeyElementTag[] = "TAG"; 47 const char AnnotationKeyElementTag[] = "TAG";
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after
79 default: 79 default:
80 ASSERT_NOT_REACHED(); 80 ASSERT_NOT_REACHED();
81 return "<unknown>"; 81 return "<unknown>";
82 } 82 }
83 } 83 }
84 84
85 } 85 }
86 86
87 namespace blink { 87 namespace blink {
88 88
89 void GraphicsContextAnnotator::annotate(const PaintInfo& paintInfo, const Render Object* object) 89 void GraphicsContextAnnotator::annotate(const PaintInfo& paintInfo, const Layout Object* object)
90 { 90 {
91 ASSERT(!m_context); 91 ASSERT(!m_context);
92 92
93 ASSERT(paintInfo.context); 93 ASSERT(paintInfo.context);
94 ASSERT(object); 94 ASSERT(object);
95 95
96 AnnotationList annotations; 96 AnnotationList annotations;
97 AnnotationModeFlags mode = paintInfo.context->annotationMode(); 97 AnnotationModeFlags mode = paintInfo.context->annotationMode();
98 Element* element = object->node() && object->node()->isElementNode() ? toEle ment(object->node()) : 0; 98 Element* element = object->node() && object->node()->isElementNode() ? toEle ment(object->node()) : 0;
99 99
(...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after
134 m_context->beginAnnotation(annotations); 134 m_context->beginAnnotation(annotations);
135 } 135 }
136 136
137 void GraphicsContextAnnotator::finishAnnotation() 137 void GraphicsContextAnnotator::finishAnnotation()
138 { 138 {
139 ASSERT(m_context); 139 ASSERT(m_context);
140 m_context->endAnnotation(); 140 m_context->endAnnotation();
141 } 141 }
142 142
143 } // namespace blink 143 } // namespace blink
OLDNEW
« no previous file with comments | « Source/core/paint/GraphicsContextAnnotator.h ('k') | Source/core/paint/InlineTextBoxPainter.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698