OLD | NEW |
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 Loading... |
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 Loading... |
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 } |
OLD | NEW |