Changeset 152491 in webkit
- Timestamp:
- Jul 9, 2013 4:31:14 AM (11 years ago)
- Location:
- trunk/Source/WebCore
- Files:
-
- 6 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Source/WebCore/ChangeLog
r152490 r152491 1 2013-07-09 Gyuyoung Kim <gyuyoung.kim@samsung.com> 2 3 Use toSVGFontElement() instead of static_cast<SVGFontElement*> 4 https://bugs.webkit.org/show_bug.cgi?id=118496 5 6 Reviewed by Andreas Kling. 7 8 As a step to change static_cast with toXXX, static_cast<SVGFontElement*> can 9 be changed with toSVGFontElement(). 10 11 Blink merge from https://src.chromium.org/viewvc/blink?view=rev&revision=153761 12 13 * svg/SVGFontElement.h: 14 (WebCore::toSVGFontElement): 15 * svg/SVGFontFaceElement.cpp: 16 (WebCore::SVGFontFaceElement::rebuildFontFace): 17 * svg/SVGGlyphElement.cpp: 18 (WebCore::SVGGlyphElement::invalidateGlyphCache): 19 * svg/SVGHKernElement.cpp: 20 (WebCore::SVGHKernElement::insertedInto): 21 (WebCore::SVGHKernElement::removedFrom): 22 * svg/SVGVKernElement.cpp: 23 (WebCore::SVGVKernElement::insertedInto): 24 (WebCore::SVGVKernElement::removedFrom): 25 1 26 2013-07-09 Christophe Dumez <ch.dumez@sisa.samsung.com> 2 27 -
trunk/Source/WebCore/svg/SVGFontElement.h
r149960 r152491 28 28 #include "SVGGlyphElement.h" 29 29 #include "SVGGlyphMap.h" 30 #include "SVGNames.h" 30 31 #include "SVGParserUtilities.h" 31 32 #include "SVGStyledElement.h" … … 90 91 }; 91 92 93 inline SVGFontElement* toSVGFontElement(Node* node) 94 { 95 ASSERT_WITH_SECURITY_IMPLICATION(!node || node->hasTagName(SVGNames::fontTag)); 96 return static_cast<SVGFontElement*>(node); 97 } 98 92 99 } // namespace WebCore 93 100 -
trunk/Source/WebCore/svg/SVGFontFaceElement.cpp
r148397 r152491 289 289 290 290 if (describesParentFont) { 291 m_fontElement = static_cast<SVGFontElement*>(parentNode());291 m_fontElement = toSVGFontElement(parentNode()); 292 292 293 293 list = CSSValueList::createCommaSeparated(); -
trunk/Source/WebCore/svg/SVGGlyphElement.cpp
r135069 r152491 48 48 { 49 49 ContainerNode* fontNode = parentNode(); 50 if (fontNode && fontNode->hasTagName(SVGNames::fontTag)) { 51 if (SVGFontElement* element = static_cast<SVGFontElement*>(fontNode)) 52 element->invalidateGlyphCache(); 53 } 50 if (fontNode && fontNode->hasTagName(SVGNames::fontTag)) 51 toSVGFontElement(fontNode)->invalidateGlyphCache(); 54 52 } 55 53 -
trunk/Source/WebCore/svg/SVGHKernElement.cpp
r118192 r152491 45 45 { 46 46 ContainerNode* fontNode = parentNode(); 47 if (fontNode && fontNode->hasTagName(SVGNames::fontTag)) { 48 if (SVGFontElement* element = static_cast<SVGFontElement*>(fontNode)) 49 element->invalidateGlyphCache(); 50 } 47 if (fontNode && fontNode->hasTagName(SVGNames::fontTag)) 48 toSVGFontElement(fontNode)->invalidateGlyphCache(); 51 49 52 50 return SVGElement::insertedInto(rootParent); … … 56 54 { 57 55 ContainerNode* fontNode = parentNode(); 58 if (fontNode && fontNode->hasTagName(SVGNames::fontTag)) { 59 if (SVGFontElement* element = static_cast<SVGFontElement*>(fontNode)) 60 element->invalidateGlyphCache(); 61 } 56 if (fontNode && fontNode->hasTagName(SVGNames::fontTag)) 57 toSVGFontElement(fontNode)->invalidateGlyphCache(); 62 58 63 59 SVGElement::removedFrom(rootParent); -
trunk/Source/WebCore/svg/SVGVKernElement.cpp
r118192 r152491 44 44 if (rootParent->inDocument()) { 45 45 ContainerNode* fontNode = parentNode(); 46 if (fontNode && fontNode->hasTagName(SVGNames::fontTag)) { 47 if (SVGFontElement* element = static_cast<SVGFontElement*>(fontNode)) 48 element->invalidateGlyphCache(); 49 } 46 if (fontNode && fontNode->hasTagName(SVGNames::fontTag)) 47 toSVGFontElement(fontNode)->invalidateGlyphCache(); 50 48 } 51 49 … … 56 54 { 57 55 ContainerNode* fontNode = parentNode(); 58 if (fontNode && fontNode->hasTagName(SVGNames::fontTag)) { 59 if (SVGFontElement* element = static_cast<SVGFontElement*>(fontNode)) 60 element->invalidateGlyphCache(); 61 } 56 if (fontNode && fontNode->hasTagName(SVGNames::fontTag)) 57 toSVGFontElement(fontNode)->invalidateGlyphCache(); 58 62 59 SVGElement::removedFrom(rootParent); 63 60 }
Note: See TracChangeset
for help on using the changeset viewer.