一、作用
EventDispatcher是egret 的事件派发器类,负责进行事件的发送和侦听。
二、用法
EventManager.ts
class EventManager extends egret.EventDispatcher {
private static _instance: any;
public constructor(target:egret.IEventDispatcher = null) {
super(target);
}
private static getInstance() {
EventManager._instance = EventManager._instance || new