#include "config.h"
#include "core/svg/SVGStyleElement.h"
+#include "core/MediaTypeNames.h"
#include "core/css/CSSStyleSheet.h"
#include "wtf/StdLibExtras.h"
-namespace WebCore {
+namespace blink {
inline SVGStyleElement::SVGStyleElement(Document& document, bool createdByParser)
: SVGElement(SVGNames::styleTag, document)
, StyleElement(&document, createdByParser)
, m_svgLoadEventTimer(this, &SVGElement::svgLoadEventTimerFired)
{
- ScriptWrappable::init(this);
}
SVGStyleElement::~SVGStyleElement()
#endif
}
-PassRefPtr<SVGStyleElement> SVGStyleElement::create(Document& document, bool createdByParser)
+PassRefPtrWillBeRawPtr<SVGStyleElement> SVGStyleElement::create(Document& document, bool createdByParser)
{
- return adoptRef(new SVGStyleElement(document, createdByParser));
+ return adoptRefWillBeNoop(new SVGStyleElement(document, createdByParser));
}
bool SVGStyleElement::disabled() const
const AtomicString& SVGStyleElement::media() const
{
- DEFINE_STATIC_LOCAL(const AtomicString, defaultValue, ("all", AtomicString::ConstructFromLiteral));
const AtomicString& n = fastGetAttribute(SVGNames::mediaAttr);
- return n.isNull() ? defaultValue : n;
+ return n.isNull() ? MediaTypeNames::all : n;
}
void SVGStyleElement::setMedia(const AtomicString& media)
StyleElement::removedFromDocument(document(), this);
}
-void SVGStyleElement::childrenChanged(bool changedByParser, Node* beforeChange, Node* afterChange, int childCountDelta)
+void SVGStyleElement::childrenChanged(const ChildrenChange& change)
{
- SVGElement::childrenChanged(changedByParser, beforeChange, afterChange, childCountDelta);
+ SVGElement::childrenChanged(change);
StyleElement::childrenChanged(this);
}