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

Side by Side Diff: Source/core/rendering/svg/RenderSVGRoot.cpp

Issue 143323014: *** DO NOT LAND *** Attempt to understand Regions complexity Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 11 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) 2004, 2005, 2007 Nikolas Zimmermann <zimmermann@kde.org> 2 * Copyright (C) 2004, 2005, 2007 Nikolas Zimmermann <zimmermann@kde.org>
3 * Copyright (C) 2004, 2005, 2007, 2008, 2009 Rob Buis <buis@kde.org> 3 * Copyright (C) 2004, 2005, 2007, 2008, 2009 Rob Buis <buis@kde.org>
4 * Copyright (C) 2007 Eric Seidel <eric@webkit.org> 4 * Copyright (C) 2007 Eric Seidel <eric@webkit.org>
5 * Copyright (C) 2009 Google, Inc. 5 * Copyright (C) 2009 Google, Inc.
6 * Copyright (C) Research In Motion Limited 2011. All rights reserved. 6 * Copyright (C) Research In Motion Limited 2011. All rights reserved.
7 * 7 *
8 * This library is free software; you can redistribute it and/or 8 * This library is free software; you can redistribute it and/or
9 * modify it under the terms of the GNU Library General Public 9 * modify it under the terms of the GNU Library General Public
10 * License as published by the Free Software Foundation; either 10 * License as published by the Free Software Foundation; either
(...skipping 241 matching lines...) Expand 10 before | Expand all | Expand 10 after
252 SVGResources* resources = SVGResourcesCache::cachedResourcesForRenderObj ect(this); 252 SVGResources* resources = SVGResourcesCache::cachedResourcesForRenderObj ect(this);
253 if (!resources || !resources->filter()) 253 if (!resources || !resources->filter())
254 return; 254 return;
255 } 255 }
256 256
257 // Make a copy of the PaintInfo because applyTransform will modify the damag e rect. 257 // Make a copy of the PaintInfo because applyTransform will modify the damag e rect.
258 PaintInfo childPaintInfo(paintInfo); 258 PaintInfo childPaintInfo(paintInfo);
259 childPaintInfo.context->save(); 259 childPaintInfo.context->save();
260 260
261 // Apply initial viewport clip - not affected by overflow handling 261 // Apply initial viewport clip - not affected by overflow handling
262 childPaintInfo.context->clip(pixelSnappedIntRect(overflowClipRect(paintOffse t, paintInfo.renderRegion))); 262 childPaintInfo.context->clip(pixelSnappedIntRect(overflowClipRect(paintOffse t)));
263 263
264 // Convert from container offsets (html renderers) to a relative transform ( svg renderers). 264 // Convert from container offsets (html renderers) to a relative transform ( svg renderers).
265 // Transform from our paint container's coordinate system to our local coord s. 265 // Transform from our paint container's coordinate system to our local coord s.
266 IntPoint adjustedPaintOffset = roundedIntPoint(paintOffset); 266 IntPoint adjustedPaintOffset = roundedIntPoint(paintOffset);
267 childPaintInfo.applyTransform(AffineTransform::translation(adjustedPaintOffs et.x(), adjustedPaintOffset.y()) * localToBorderBoxTransform()); 267 childPaintInfo.applyTransform(AffineTransform::translation(adjustedPaintOffs et.x(), adjustedPaintOffset.y()) * localToBorderBoxTransform());
268 268
269 // SVGRenderingContext must be destroyed before we restore the childPaintInf o.context, because a filter may have 269 // SVGRenderingContext must be destroyed before we restore the childPaintInf o.context, because a filter may have
270 // changed the context and it is only reverted when the SVGRenderingContext destructor finishes applying the filter. 270 // changed the context and it is only reverted when the SVGRenderingContext destructor finishes applying the filter.
271 { 271 {
272 SVGRenderingContext renderingContext; 272 SVGRenderingContext renderingContext;
(...skipping 165 matching lines...) Expand 10 before | Expand all | Expand 10 after
438 438
439 bool RenderSVGRoot::hasRelativeLogicalHeight() const 439 bool RenderSVGRoot::hasRelativeLogicalHeight() const
440 { 440 {
441 SVGSVGElement* svg = toSVGSVGElement(node()); 441 SVGSVGElement* svg = toSVGSVGElement(node());
442 ASSERT(svg); 442 ASSERT(svg);
443 443
444 return svg->intrinsicHeight(SVGSVGElement::IgnoreCSSProperties).isPercent(); 444 return svg->intrinsicHeight(SVGSVGElement::IgnoreCSSProperties).isPercent();
445 } 445 }
446 446
447 } 447 }
OLDNEW
« no previous file with comments | « Source/core/rendering/style/StyleRareNonInheritedData.cpp ('k') | Source/devtools/Inspector-1.1.json » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698