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

Unified Diff: Source/core/svg/animation/SVGSMILElement.cpp

Issue 106263004: [SVG] A minor clean up related to event listener attributes (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 6 years, 12 months 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 | « Source/core/svg/SVGElement.cpp ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/svg/animation/SVGSMILElement.cpp
diff --git a/Source/core/svg/animation/SVGSMILElement.cpp b/Source/core/svg/animation/SVGSMILElement.cpp
index 7dbc0aedd5b496537235f8ba4d6f8bbac8c6dc63..e3a388498d2a323bfaaf2533427860963e40592d 100644
--- a/Source/core/svg/animation/SVGSMILElement.cpp
+++ b/Source/core/svg/animation/SVGSMILElement.cpp
@@ -29,6 +29,7 @@
#include "SVGNames.h"
#include "XLinkNames.h"
#include "bindings/v8/ExceptionStatePlaceholder.h"
+#include "bindings/v8/ScriptEventListener.h"
#include "core/dom/Document.h"
#include "core/events/EventListener.h"
#include "core/events/EventSender.h"
@@ -517,6 +518,12 @@ void SVGSMILElement::parseAttribute(const QualifiedName& name, const AtomicStrin
parseBeginOrEnd(value.string(), End);
if (inDocument())
connectConditions();
+ } else if (name == SVGNames::onbeginAttr) {
+ setAttributeEventListener(EventTypeNames::beginEvent, createAttributeEventListener(this, name, value));
+ } else if (name == SVGNames::onendAttr) {
+ setAttributeEventListener(EventTypeNames::endEvent, createAttributeEventListener(this, name, value));
+ } else if (name == SVGNames::onrepeatAttr) {
+ setAttributeEventListener(EventTypeNames::repeatEvent, createAttributeEventListener(this, name, value));
} else
SVGElement::parseAttribute(name, value);
}
« no previous file with comments | « Source/core/svg/SVGElement.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698