Chromium Code Reviews| Index: Source/core/html/HTMLMarqueeElement.js |
| diff --git a/Source/core/html/HTMLMarqueeElement.js b/Source/core/html/HTMLMarqueeElement.js |
| index b18756327e29177580caa63a03ee0f0a09b72ccc..b0e00a1d0d27095d74928356f0c5758112c094fb 100644 |
| --- a/Source/core/html/HTMLMarqueeElement.js |
| +++ b/Source/core/html/HTMLMarqueeElement.js |
| @@ -81,32 +81,6 @@ installClass('HTMLMarqueeElement', function(global) { |
| }); |
| } |
| - function defineInlineEventHandler(prototype, eventName) { |
| - var propertyName = 'on' + eventName; |
| - // FIXME: We should use symbols here instead. |
| - var functionPropertyName = propertyName + 'Function_'; |
| - var eventHandlerPropertyName = propertyName + 'EventHandler_'; |
| - Object.defineProperty(prototype, propertyName, { |
| - get: function() { |
| - var func = this[functionPropertyName]; |
| - return func || null; |
| - }, |
| - set: function(value) { |
| - var oldEventHandler = this[eventHandlerPropertyName]; |
| - if (oldEventHandler) |
| - this.removeEventListener(eventName, oldEventHandler); |
| - // Notice that we wrap |value| in an anonymous function so that the |
| - // author can't call removeEventListener themselves to unregister the |
| - // inline event handler. |
| - var newEventHandler = value ? function() { value.apply(this, arguments) } : null; |
| - if (newEventHandler) |
| - this.addEventListener(eventName, newEventHandler); |
| - this[functionPropertyName] = value; |
| - this[eventHandlerPropertyName] = newEventHandler; |
| - }, |
| - }); |
| - } |
| - |
| var HTMLMarqueeElementPrototype = Object.create(HTMLElement.prototype); |
| reflectAttribute(HTMLMarqueeElementPrototype, 'behavior', 'behavior'); |
| @@ -118,10 +92,6 @@ installClass('HTMLMarqueeElement', function(global) { |
| reflectAttribute(HTMLMarqueeElementPrototype, 'width', 'width'); |
| reflectBooleanAttribute(HTMLMarqueeElementPrototype, 'truespeed', 'trueSpeed'); |
| - defineInlineEventHandler(HTMLMarqueeElementPrototype, 'start'); |
| - defineInlineEventHandler(HTMLMarqueeElementPrototype, 'finish'); |
| - defineInlineEventHandler(HTMLMarqueeElementPrototype, 'bounce'); |
|
haraken
2014/07/15 12:57:07
I removed these event handlers, since we haven't y
|
| - |
| HTMLMarqueeElementPrototype.createdCallback = function() { |
|
haraken
2014/07/15 12:57:07
abarth@: When and how are you assuming that these
abarth-chromium
2014/07/15 17:10:07
These callbacks are all defined by http://w3c.gith
|
| var shadow = this.createShadowRoot(); |
| var style = global.document.createElement('style'); |
| @@ -364,7 +334,6 @@ installClass('HTMLMarqueeElement', function(global) { |
| HTMLMarqueeElementPrototype.continue_ = function() { |
| if (!this.shouldContinue_()) { |
| this.player_ = null; |
| - this.dispatchEvent(new Event('finish', false, true)); |
| return; |
| } |
| @@ -385,8 +354,6 @@ installClass('HTMLMarqueeElement', function(global) { |
| return; |
| ++this.loopCount_; |
| this.continue_(); |
| - if (this.player_ && this.behavior === kBehaviorAlternate) |
| - this.dispatchEvent(new Event('bounce', false, true)); |
| }.bind(this)); |
| }; |
| @@ -397,7 +364,6 @@ installClass('HTMLMarqueeElement', function(global) { |
| this.continueCallback_ = null; |
| this.continue_(); |
| }.bind(this)); |
| - this.dispatchEvent(new Event('start', false, true)); |
| }; |
| HTMLMarqueeElementPrototype.stop = function() { |