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/RenderSVGResourceGradient.cpp

Issue 622393002: Introduce new entry-points for non-paint-server RenderSVGResources (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 2 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 Nikolas Zimmermann <zimmermann@kde.org> 2 * Copyright (C) 2006 Nikolas Zimmermann <zimmermann@kde.org>
3 * Copyright (C) 2008 Eric Seidel <eric@webkit.org> 3 * Copyright (C) 2008 Eric Seidel <eric@webkit.org>
4 * Copyright (C) 2008 Dirk Schulze <krit@webkit.org> 4 * Copyright (C) 2008 Dirk Schulze <krit@webkit.org>
5 * Copyright (C) Research In Motion Limited 2010. All rights reserved. 5 * Copyright (C) Research In Motion Limited 2010. All rights reserved.
6 * 6 *
7 * This library is free software; you can redistribute it and/or 7 * This library is free software; you can redistribute it and/or
8 * modify it under the terms of the GNU Library General Public 8 * modify it under the terms of the GNU Library General Public
9 * License as published by the Free Software Foundation; either 9 * License as published by the Free Software Foundation; either
10 * version 2 of the License, or (at your option) any later version. 10 * version 2 of the License, or (at your option) any later version.
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after
48 ASSERT(client); 48 ASSERT(client);
49 m_gradientMap.remove(client); 49 m_gradientMap.remove(client);
50 markClientForInvalidation(client, markForInvalidation ? PaintInvalidation : ParentOnlyInvalidation); 50 markClientForInvalidation(client, markForInvalidation ? PaintInvalidation : ParentOnlyInvalidation);
51 } 51 }
52 52
53 bool RenderSVGResourceGradient::applyResource(RenderObject* object, RenderStyle* style, GraphicsContext*& context, unsigned short resourceMode) 53 bool RenderSVGResourceGradient::applyResource(RenderObject* object, RenderStyle* style, GraphicsContext*& context, unsigned short resourceMode)
54 { 54 {
55 ASSERT(object); 55 ASSERT(object);
56 ASSERT(style); 56 ASSERT(style);
57 ASSERT(context); 57 ASSERT(context);
58 ASSERT(resourceMode != ApplyToDefaultMode);
59 58
60 clearInvalidationMask(); 59 clearInvalidationMask();
61 60
62 // Be sure to synchronize all SVG properties on the gradientElement _before_ processing any further. 61 // Be sure to synchronize all SVG properties on the gradientElement _before_ processing any further.
63 // Otherwhise the call to collectGradientAttributes() in createTileImage(), may cause the SVG DOM property 62 // Otherwhise the call to collectGradientAttributes() in createTileImage(), may cause the SVG DOM property
64 // synchronization to kick in, which causes removeAllClientsFromCache() to b e called, which in turn deletes our 63 // synchronization to kick in, which causes removeAllClientsFromCache() to b e called, which in turn deletes our
65 // GradientData object! Leaving out the line below will cause svg/dynamic-up dates/SVG*GradientElement-svgdom* to crash. 64 // GradientData object! Leaving out the line below will cause svg/dynamic-up dates/SVG*GradientElement-svgdom* to crash.
66 SVGGradientElement* gradientElement = toSVGGradientElement(element()); 65 SVGGradientElement* gradientElement = toSVGGradientElement(element());
67 if (!gradientElement) 66 if (!gradientElement)
68 return false; 67 return false;
(...skipping 84 matching lines...) Expand 10 before | Expand all | Expand 10 after
153 return SpreadMethodReflect; 152 return SpreadMethodReflect;
154 case SVGSpreadMethodRepeat: 153 case SVGSpreadMethodRepeat:
155 return SpreadMethodRepeat; 154 return SpreadMethodRepeat;
156 } 155 }
157 156
158 ASSERT_NOT_REACHED(); 157 ASSERT_NOT_REACHED();
159 return SpreadMethodPad; 158 return SpreadMethodPad;
160 } 159 }
161 160
162 } 161 }
OLDNEW
« no previous file with comments | « Source/core/rendering/svg/RenderSVGResourceFilter.cpp ('k') | Source/core/rendering/svg/RenderSVGResourceMarker.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698