aboutsummaryrefslogtreecommitdiffstats
path: root/src/types/EventTarget.js
diff options
context:
space:
mode:
authorUlrich-Matthias Schäfer <ulima.ums@googlemail.com>2020-04-08 08:47:16 +1000
committerUlrich-Matthias Schäfer <ulima.ums@googlemail.com>2020-04-08 08:47:16 +1000
commita4a532d5b886d1e59a96cee7453f3b2ffb8f9285 (patch)
treeaad52d48b9ff6872ed541d53049a75b4c528a74a /src/types/EventTarget.js
parentd927f2d225d74fd3b3f41b298a19f6ba075702cf (diff)
downloadsvg.js-a4a532d5b886d1e59a96cee7453f3b2ffb8f9285.tar.gz
svg.js-a4a532d5b886d1e59a96cee7453f3b2ffb8f9285.zip
tests for EventTarget
Diffstat (limited to 'src/types/EventTarget.js')
-rw-r--r--src/types/EventTarget.js13
1 files changed, 4 insertions, 9 deletions
diff --git a/src/types/EventTarget.js b/src/types/EventTarget.js
index b4a137a..6889605 100644
--- a/src/types/EventTarget.js
+++ b/src/types/EventTarget.js
@@ -3,15 +3,10 @@ import { register } from '../utils/adopter.js'
import Base from './Base.js'
export default class EventTarget extends Base {
- constructor ({ events = {} } = {}) {
- super()
- this.events = events
- }
-
addEventListener () {}
- dispatch (event, data) {
- return dispatch(this, event, data)
+ dispatch (event, data, options) {
+ return dispatch(this, event, data, options)
}
dispatchEvent (event) {
@@ -30,8 +25,8 @@ export default class EventTarget extends Base {
}
// Fire given event
- fire (event, data) {
- this.dispatch(event, data)
+ fire (event, data, options) {
+ this.dispatch(event, data, options)
return this
}