浏览代码

Added a read-only property EventCaller.watchedEvents which is an array of event names currently being listened for.

dev-tmpl
Bryan Miller 6 年前
父节点
当前提交
162f6a2080
共有 1 个文件被更改,包括 7 次插入0 次删除
  1. +7
    -0
      app/js/EventCaller.js

+ 7
- 0
app/js/EventCaller.js 查看文件

@@ -20,6 +20,13 @@ export class EventCaller{
}

/**
* @type {Array[string]}
*/
get watchedEvents(){
return Object.keys(this.__listeners);
}

/**
* Returns true if the given callback is listening for the given event, and false otherwise.
* @param {string} eventName - The name of the event to check.
* @param {Function} callback - The function/method to check for

正在加载...
取消
保存