##// END OF EJS Templates
bind event handler methods marked with `@on` before subscribing the event
cin -
r77:bc7556143fe5 v1.2.2 default
parent child
Show More
@@ -62,7 +62,7 export abstract class DjxWidgetBase<Attr
62 62 this._eventHandlers.forEach(({eventName, handlerMethod}) => {
63 63 const handler = this[handlerMethod as keyof this];
64 64 if (typeof handler === "function")
65 this.on(eventName, handler);
65 this.on(eventName, handler.bind(this));
66 66 });
67 67 }
68 68
General Comments 0
You need to be logged in to leave comments. Login now