Use extends and super for events/EventTarget
This commit is contained in:
@@ -1,7 +1,6 @@
|
||||
/**
|
||||
* @module ol/events/EventTarget
|
||||
*/
|
||||
import {inherits} from '../util.js';
|
||||
import Disposable from '../Disposable.js';
|
||||
import {unlistenAll} from '../events.js';
|
||||
import {UNDEFINED} from '../functions.js';
|
||||
@@ -29,12 +28,11 @@ import Event from '../events/Event.js';
|
||||
* returns false.
|
||||
*
|
||||
* @constructor
|
||||
* @extends {module:ol/Disposable}
|
||||
*/
|
||||
class EventTarget {
|
||||
class EventTarget extends Disposable {
|
||||
constructor() {
|
||||
|
||||
Disposable.call(this);
|
||||
super();
|
||||
|
||||
/**
|
||||
* @private
|
||||
@@ -165,7 +163,5 @@ class EventTarget {
|
||||
}
|
||||
}
|
||||
|
||||
inherits(EventTarget, Disposable);
|
||||
|
||||
|
||||
export default EventTarget;
|
||||
|
||||
Reference in New Issue
Block a user