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

Side by Side Diff: Source/core/rendering/svg/RenderSVGBlock.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) 2006 Apple Computer, Inc. 2 * Copyright (C) 2006 Apple Computer, Inc.
3 * Copyright (C) 2007 Nikolas Zimmermann <zimmermann@kde.org> 3 * Copyright (C) 2007 Nikolas Zimmermann <zimmermann@kde.org>
4 * Copyright (C) Research In Motion Limited 2010. All rights reserved. 4 * Copyright (C) Research In Motion Limited 2010. All rights reserved.
5 * 5 *
6 * This library is free software; you can redistribute it and/or 6 * This library is free software; you can redistribute it and/or
7 * modify it under the terms of the GNU Library General Public 7 * modify it under the terms of the GNU Library General Public
8 * License as published by the Free Software Foundation; either 8 * License as published by the Free Software Foundation; either
9 * version 2 of the License, or (at your option) any later version. 9 * version 2 of the License, or (at your option) any later version.
10 * 10 *
(...skipping 79 matching lines...) Expand 10 before | Expand all | Expand 10 after
90 90
91 RenderBlock::styleDidChange(diff, oldStyle); 91 RenderBlock::styleDidChange(diff, oldStyle);
92 SVGResourcesCache::clientStyleChanged(this, diff, style()); 92 SVGResourcesCache::clientStyleChanged(this, diff, style());
93 } 93 }
94 94
95 void RenderSVGBlock::mapLocalToContainer(const LayoutLayerModelObject* paintInva lidationContainer, TransformState& transformState, MapCoordinatesFlags, bool* wa sFixed, const PaintInvalidationState* paintInvalidationState) const 95 void RenderSVGBlock::mapLocalToContainer(const LayoutLayerModelObject* paintInva lidationContainer, TransformState& transformState, MapCoordinatesFlags, bool* wa sFixed, const PaintInvalidationState* paintInvalidationState) const
96 { 96 {
97 SVGRenderSupport::mapLocalToContainer(this, paintInvalidationContainer, tran sformState, wasFixed, paintInvalidationState); 97 SVGRenderSupport::mapLocalToContainer(this, paintInvalidationContainer, tran sformState, wasFixed, paintInvalidationState);
98 } 98 }
99 99
100 const RenderObject* RenderSVGBlock::pushMappingToContainer(const LayoutLayerMode lObject* ancestorToStopAt, RenderGeometryMap& geometryMap) const 100 const LayoutObject* RenderSVGBlock::pushMappingToContainer(const LayoutLayerMode lObject* ancestorToStopAt, RenderGeometryMap& geometryMap) const
101 { 101 {
102 return SVGRenderSupport::pushMappingToContainer(this, ancestorToStopAt, geom etryMap); 102 return SVGRenderSupport::pushMappingToContainer(this, ancestorToStopAt, geom etryMap);
103 } 103 }
104 104
105 LayoutRect RenderSVGBlock::clippedOverflowRectForPaintInvalidation(const LayoutL ayerModelObject* paintInvalidationContainer, const PaintInvalidationState* paint InvalidationState) const 105 LayoutRect RenderSVGBlock::clippedOverflowRectForPaintInvalidation(const LayoutL ayerModelObject* paintInvalidationContainer, const PaintInvalidationState* paint InvalidationState) const
106 { 106 {
107 return SVGRenderSupport::clippedOverflowRectForPaintInvalidation(this, paint InvalidationContainer, paintInvalidationState); 107 return SVGRenderSupport::clippedOverflowRectForPaintInvalidation(this, paint InvalidationContainer, paintInvalidationState);
108 } 108 }
109 109
110 void RenderSVGBlock::mapRectToPaintInvalidationBacking(const LayoutLayerModelObj ect* paintInvalidationContainer, LayoutRect& rect, const PaintInvalidationState* paintInvalidationState) const 110 void RenderSVGBlock::mapRectToPaintInvalidationBacking(const LayoutLayerModelObj ect* paintInvalidationContainer, LayoutRect& rect, const PaintInvalidationState* paintInvalidationState) const
(...skipping 12 matching lines...) Expand all
123 123
124 void RenderSVGBlock::invalidateTreeIfNeeded(const PaintInvalidationState& paintI nvalidationState) 124 void RenderSVGBlock::invalidateTreeIfNeeded(const PaintInvalidationState& paintI nvalidationState)
125 { 125 {
126 if (!shouldCheckForPaintInvalidation(paintInvalidationState)) 126 if (!shouldCheckForPaintInvalidation(paintInvalidationState))
127 return; 127 return;
128 128
129 if (paintInvalidationState.cachedOffsetsEnabled()) { 129 if (paintInvalidationState.cachedOffsetsEnabled()) {
130 m_cachedPaintInvalidationTransform = paintInvalidationState.svgTransform (); 130 m_cachedPaintInvalidationTransform = paintInvalidationState.svgTransform ();
131 } else { 131 } else {
132 m_cachedPaintInvalidationTransform.makeIdentity(); 132 m_cachedPaintInvalidationTransform.makeIdentity();
133 RenderObject* next = parent(); 133 LayoutObject* next = parent();
134 while (!next->isSVGRoot()) { 134 while (!next->isSVGRoot()) {
135 m_cachedPaintInvalidationTransform = next->localToParentTransform() * m_cachedPaintInvalidationTransform; 135 m_cachedPaintInvalidationTransform = next->localToParentTransform() * m_cachedPaintInvalidationTransform;
136 next = next->parent(); 136 next = next->parent();
137 ASSERT(next); 137 ASSERT(next);
138 } 138 }
139 m_cachedPaintInvalidationTransform = toRenderSVGRoot(next)->localToBorde rBoxTransform() * m_cachedPaintInvalidationTransform; 139 m_cachedPaintInvalidationTransform = toRenderSVGRoot(next)->localToBorde rBoxTransform() * m_cachedPaintInvalidationTransform;
140 } 140 }
141 141
142 ForceHorriblySlowRectMapping slowRectMapping(&paintInvalidationState); 142 ForceHorriblySlowRectMapping slowRectMapping(&paintInvalidationState);
143 RenderBlockFlow::invalidateTreeIfNeeded(paintInvalidationState); 143 RenderBlockFlow::invalidateTreeIfNeeded(paintInvalidationState);
144 } 144 }
145 145
146 void RenderSVGBlock::updatePaintInfoRect(IntRect& rect) 146 void RenderSVGBlock::updatePaintInfoRect(IntRect& rect)
147 { 147 {
148 if (rect != LayoutRect::infiniteRect()) { 148 if (rect != LayoutRect::infiniteRect()) {
149 AffineTransform transformToRoot = m_cachedPaintInvalidationTransform * l ocalTransform(); 149 AffineTransform transformToRoot = m_cachedPaintInvalidationTransform * l ocalTransform();
150 rect = enclosingIntRect(transformToRoot.inverse().mapRect(FloatRect(rect ))); 150 rect = enclosingIntRect(transformToRoot.inverse().mapRect(FloatRect(rect )));
151 } 151 }
152 } 152 }
153 153
154 } 154 }
OLDNEW
« no previous file with comments | « Source/core/rendering/svg/RenderSVGBlock.h ('k') | Source/core/rendering/svg/RenderSVGContainer.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698