Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(424)

Unified Diff: third_party/WebKit/Source/core/html/HTMLScriptElement.cpp

Issue 1496773002: Move code in some attributeChanged overrides to parseAttribute. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « third_party/WebKit/Source/core/html/HTMLScriptElement.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/core/html/HTMLScriptElement.cpp
diff --git a/third_party/WebKit/Source/core/html/HTMLScriptElement.cpp b/third_party/WebKit/Source/core/html/HTMLScriptElement.cpp
index b10b52a3ba90400de3367e7f6a69766fa706bd27..3284714781ace7748b3f935844e6df19aa4f56da 100644
--- a/third_party/WebKit/Source/core/html/HTMLScriptElement.cpp
+++ b/third_party/WebKit/Source/core/html/HTMLScriptElement.cpp
@@ -79,19 +79,14 @@ void HTMLScriptElement::didMoveToNewDocument(Document& oldDocument)
void HTMLScriptElement::parseAttribute(const QualifiedName& name, const AtomicString& oldValue, const AtomicString& value)
{
- if (name == srcAttr)
+ if (name == srcAttr) {
m_loader->handleSourceAttribute(value);
- else if (name == asyncAttr)
+ logEventIfIsolatedWorldAndInDocument("blinkSetAttribute", "script", srcAttr.toString(), oldValue, value);
+ } else if (name == asyncAttr) {
m_loader->handleAsyncAttribute();
- else
+ } else {
HTMLElement::parseAttribute(name, oldValue, value);
-}
-
-void HTMLScriptElement::attributeChanged(const QualifiedName& name, const AtomicString& oldValue, const AtomicString& newValue, AttributeModificationReason reason)
-{
- if (name == srcAttr)
- logEventIfIsolatedWorldAndInDocument("blinkSetAttribute", "script", srcAttr.toString(), oldValue, newValue);
- HTMLElement::attributeChanged(name, oldValue, newValue, reason);
+ }
}
Node::InsertionNotificationRequest HTMLScriptElement::insertedInto(ContainerNode* insertionPoint)
« no previous file with comments | « third_party/WebKit/Source/core/html/HTMLScriptElement.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698