summaryrefslogtreecommitdiff
path: root/Source/WebCore/html/HTMLScriptElement.h
diff options
context:
space:
mode:
authorKonstantin Tokarev <annulen@yandex.ru>2016-08-25 19:20:41 +0300
committerKonstantin Tokarev <annulen@yandex.ru>2017-02-02 12:30:55 +0000
commit6882a04fb36642862b11efe514251d32070c3d65 (patch)
treeb7959826000b061fd5ccc7512035c7478742f7b0 /Source/WebCore/html/HTMLScriptElement.h
parentab6df191029eeeb0b0f16f127d553265659f739e (diff)
downloadqtwebkit-6882a04fb36642862b11efe514251d32070c3d65.tar.gz
Imported QtWebKit TP3 (git b57bc6801f1876c3220d5a4bfea33d620d477443)
Change-Id: I3b1d8a2808782c9f34d50240000e20cb38d3680f Reviewed-by: Konstantin Tokarev <annulen@yandex.ru>
Diffstat (limited to 'Source/WebCore/html/HTMLScriptElement.h')
-rw-r--r--Source/WebCore/html/HTMLScriptElement.h52
1 files changed, 21 insertions, 31 deletions
diff --git a/Source/WebCore/html/HTMLScriptElement.h b/Source/WebCore/html/HTMLScriptElement.h
index 7d14b5c6d..312c6626e 100644
--- a/Source/WebCore/html/HTMLScriptElement.h
+++ b/Source/WebCore/html/HTMLScriptElement.h
@@ -29,55 +29,45 @@
namespace WebCore {
-class HTMLScriptElement FINAL : public HTMLElement, public ScriptElement {
+class HTMLScriptElement final : public HTMLElement, public ScriptElement {
public:
- static PassRefPtr<HTMLScriptElement> create(const QualifiedName&, Document*, bool wasInsertedByParser, bool alreadyStarted = false);
+ static Ref<HTMLScriptElement> create(const QualifiedName&, Document&, bool wasInsertedByParser, bool alreadyStarted = false);
String text() const { return scriptContent(); }
void setText(const String&);
- KURL src() const;
+ URL src() const;
void setAsync(bool);
bool async() const;
private:
- HTMLScriptElement(const QualifiedName&, Document*, bool wasInsertedByParser, bool alreadyStarted);
+ HTMLScriptElement(const QualifiedName&, Document&, bool wasInsertedByParser, bool alreadyStarted);
- virtual void parseAttribute(const QualifiedName&, const AtomicString&) OVERRIDE;
- virtual InsertionNotificationRequest insertedInto(ContainerNode*) OVERRIDE;
- virtual void childrenChanged(bool changedByParser = false, Node* beforeChange = 0, Node* afterChange = 0, int childCountDelta = 0);
+ virtual void parseAttribute(const QualifiedName&, const AtomicString&) override;
+ virtual InsertionNotificationRequest insertedInto(ContainerNode&) override;
+ virtual void finishedInsertingSubtree() override;
+ virtual void childrenChanged(const ChildChange&) override;
- virtual bool isURLAttribute(const Attribute&) const OVERRIDE;
+ virtual bool isURLAttribute(const Attribute&) const override;
- virtual void addSubresourceAttributeURLs(ListHashSet<KURL>&) const;
+ virtual void addSubresourceAttributeURLs(ListHashSet<URL>&) const override;
- virtual String sourceAttributeValue() const;
- virtual String charsetAttributeValue() const;
- virtual String typeAttributeValue() const;
- virtual String languageAttributeValue() const;
- virtual String forAttributeValue() const;
- virtual String eventAttributeValue() const;
- virtual bool asyncAttributeValue() const;
- virtual bool deferAttributeValue() const;
- virtual bool hasSourceAttribute() const;
+ virtual String sourceAttributeValue() const override;
+ virtual String charsetAttributeValue() const override;
+ virtual String typeAttributeValue() const override;
+ virtual String languageAttributeValue() const override;
+ virtual String forAttributeValue() const override;
+ virtual String eventAttributeValue() const override;
+ virtual bool asyncAttributeValue() const override;
+ virtual bool deferAttributeValue() const override;
+ virtual bool hasSourceAttribute() const override;
- virtual void dispatchLoadEvent();
+ virtual void dispatchLoadEvent() override;
- virtual PassRefPtr<Element> cloneElementWithoutAttributesAndChildren();
+ virtual Ref<Element> cloneElementWithoutAttributesAndChildren(Document&) override;
};
-inline bool isHTMLScriptElement(Node* node)
-{
- return node->hasTagName(HTMLNames::scriptTag);
-}
-
-inline HTMLScriptElement* toHTMLScriptElement(Node* node)
-{
- ASSERT_WITH_SECURITY_IMPLICATION(!node || node->hasTagName(HTMLNames::scriptTag));
- return static_cast<HTMLScriptElement*>(node);
-}
-
} //namespace
#endif