OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2004, 2005, 2006, 2007, 2008 Nikolas Zimmermann <zimmermann@kde
.org> | 2 * Copyright (C) 2004, 2005, 2006, 2007, 2008 Nikolas Zimmermann <zimmermann@kde
.org> |
3 * Copyright (C) 2004, 2005, 2006, 2008 Rob Buis <buis@kde.org> | 3 * Copyright (C) 2004, 2005, 2006, 2008 Rob Buis <buis@kde.org> |
4 * Copyright (C) 2008 Apple Inc. All rights reserved. | 4 * Copyright (C) 2008 Apple Inc. All rights reserved. |
5 * Copyright (C) 2008 Alp Toker <alp@atoker.com> | 5 * Copyright (C) 2008 Alp Toker <alp@atoker.com> |
6 * Copyright (C) 2009 Cameron McCormack <cam@mcc.id.au> | 6 * Copyright (C) 2009 Cameron McCormack <cam@mcc.id.au> |
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 232 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
243 return String(); | 243 return String(); |
244 | 244 |
245 // Walk up the tree, to find out whether we're inside a <use> shadow tree, t
o find the right title. | 245 // Walk up the tree, to find out whether we're inside a <use> shadow tree, t
o find the right title. |
246 if (isInShadowTree()) { | 246 if (isInShadowTree()) { |
247 Element* shadowHostElement = toShadowRoot(treeScope()->rootNode())->host
(); | 247 Element* shadowHostElement = toShadowRoot(treeScope()->rootNode())->host
(); |
248 // At this time, SVG nodes are not allowed in non-<use> shadow trees, so
any shadow root we do | 248 // At this time, SVG nodes are not allowed in non-<use> shadow trees, so
any shadow root we do |
249 // have should be a use. The assert and following test is here to catch
future shadow DOM changes | 249 // have should be a use. The assert and following test is here to catch
future shadow DOM changes |
250 // that do enable SVG in a shadow tree. | 250 // that do enable SVG in a shadow tree. |
251 ASSERT(!shadowHostElement || shadowHostElement->hasTagName(SVGNames::use
Tag)); | 251 ASSERT(!shadowHostElement || shadowHostElement->hasTagName(SVGNames::use
Tag)); |
252 if (shadowHostElement && shadowHostElement->hasTagName(SVGNames::useTag)
) { | 252 if (shadowHostElement && shadowHostElement->hasTagName(SVGNames::useTag)
) { |
253 SVGUseElement* useElement = static_cast<SVGUseElement*>(shadowHostEl
ement); | 253 SVGUseElement* useElement = toSVGUseElement(shadowHostElement); |
254 | 254 |
255 // If the <use> title is not empty we found the title to use. | 255 // If the <use> title is not empty we found the title to use. |
256 String useTitle(useElement->title()); | 256 String useTitle(useElement->title()); |
257 if (!useTitle.isEmpty()) | 257 if (!useTitle.isEmpty()) |
258 return useTitle; | 258 return useTitle; |
259 } | 259 } |
260 } | 260 } |
261 | 261 |
262 // If we aren't an instance in a <use> or the <use> title was not found, the
n find the first | 262 // If we aren't an instance in a <use> or the <use> title was not found, the
n find the first |
263 // <title> child of this element. | 263 // <title> child of this element. |
(...skipping 878 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1142 } | 1142 } |
1143 | 1143 |
1144 if (name == classAttr) | 1144 if (name == classAttr) |
1145 return true; | 1145 return true; |
1146 | 1146 |
1147 return animatableAttributes.contains(name); | 1147 return animatableAttributes.contains(name); |
1148 } | 1148 } |
1149 #endif | 1149 #endif |
1150 | 1150 |
1151 } | 1151 } |
OLD | NEW |