| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) | 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) |
| 3 * (C) 1999 Antti Koivisto (koivisto@kde.org) | 3 * (C) 1999 Antti Koivisto (koivisto@kde.org) |
| 4 * (C) 2001 Dirk Mueller (mueller@kde.org) | 4 * (C) 2001 Dirk Mueller (mueller@kde.org) |
| 5 * Copyright (C) 2003, 2004, 2005, 2006, 2007, 2008 Apple Inc. All rights reserv
ed. | 5 * Copyright (C) 2003, 2004, 2005, 2006, 2007, 2008 Apple Inc. All rights reserv
ed. |
| 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 27 matching lines...) Expand all Loading... |
| 38 | 38 |
| 39 inline HTMLScriptElement::HTMLScriptElement(Document& document, bool wasInserted
ByParser, bool alreadyStarted) | 39 inline HTMLScriptElement::HTMLScriptElement(Document& document, bool wasInserted
ByParser, bool alreadyStarted) |
| 40 : HTMLElement(scriptTag, document) | 40 : HTMLElement(scriptTag, document) |
| 41 , m_loader(ScriptLoader::create(this, wasInsertedByParser, alreadyStarted)) | 41 , m_loader(ScriptLoader::create(this, wasInsertedByParser, alreadyStarted)) |
| 42 { | 42 { |
| 43 ScriptWrappable::init(this); | 43 ScriptWrappable::init(this); |
| 44 } | 44 } |
| 45 | 45 |
| 46 PassRefPtrWillBeRawPtr<HTMLScriptElement> HTMLScriptElement::create(Document& do
cument, bool wasInsertedByParser, bool alreadyStarted) | 46 PassRefPtrWillBeRawPtr<HTMLScriptElement> HTMLScriptElement::create(Document& do
cument, bool wasInsertedByParser, bool alreadyStarted) |
| 47 { | 47 { |
| 48 return adoptRefWillBeRefCountedGarbageCollected(new HTMLScriptElement(docume
nt, wasInsertedByParser, alreadyStarted)); | 48 return adoptRefWillBeNoop(new HTMLScriptElement(document, wasInsertedByParse
r, alreadyStarted)); |
| 49 } | 49 } |
| 50 | 50 |
| 51 bool HTMLScriptElement::isURLAttribute(const Attribute& attribute) const | 51 bool HTMLScriptElement::isURLAttribute(const Attribute& attribute) const |
| 52 { | 52 { |
| 53 return attribute.name() == srcAttr || HTMLElement::isURLAttribute(attribute)
; | 53 return attribute.name() == srcAttr || HTMLElement::isURLAttribute(attribute)
; |
| 54 } | 54 } |
| 55 | 55 |
| 56 bool HTMLScriptElement::hasLegalLinkAttribute(const QualifiedName& name) const | 56 bool HTMLScriptElement::hasLegalLinkAttribute(const QualifiedName& name) const |
| 57 { | 57 { |
| 58 return name == srcAttr || HTMLElement::hasLegalLinkAttribute(name); | 58 return name == srcAttr || HTMLElement::hasLegalLinkAttribute(name); |
| (...skipping 106 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 165 } | 165 } |
| 166 | 166 |
| 167 void HTMLScriptElement::dispatchLoadEvent() | 167 void HTMLScriptElement::dispatchLoadEvent() |
| 168 { | 168 { |
| 169 ASSERT(!m_loader->haveFiredLoadEvent()); | 169 ASSERT(!m_loader->haveFiredLoadEvent()); |
| 170 dispatchEvent(Event::create(EventTypeNames::load)); | 170 dispatchEvent(Event::create(EventTypeNames::load)); |
| 171 } | 171 } |
| 172 | 172 |
| 173 PassRefPtrWillBeRawPtr<Element> HTMLScriptElement::cloneElementWithoutAttributes
AndChildren() | 173 PassRefPtrWillBeRawPtr<Element> HTMLScriptElement::cloneElementWithoutAttributes
AndChildren() |
| 174 { | 174 { |
| 175 return adoptRefWillBeRefCountedGarbageCollected(new HTMLScriptElement(docume
nt(), false, m_loader->alreadyStarted())); | 175 return adoptRefWillBeNoop(new HTMLScriptElement(document(), false, m_loader-
>alreadyStarted())); |
| 176 } | 176 } |
| 177 | 177 |
| 178 } | 178 } |
| OLD | NEW |