Ejemplo n.º 1
0
 protected override void OnDispose()
 {
     mEventDic.Clear();
     mEventDic = null;
     mDispatchDic.Clear();
     mDispatchDic = null;
     mModifier.Dispose();
     mModifier = null;
 }
Ejemplo n.º 2
0
 public CallbackVo(string type, Action <CallbackVo> callback, object data = null, object target = null, uint level = 0, bool autoRemove = false, bool cancelable = false, PropModifier modifier = null)
 {
     Type       = type;
     Callback   = callback;
     Data       = data;
     Target     = target;
     Level      = level;
     AutoRemove = autoRemove;
     Cancelable = cancelable;
     mModifier  = modifier;
 }
Ejemplo n.º 3
0
        public BaseDispatcher(string name, ILogger logger = null)
        {
            Name         = name;
            mEventDic    = new Dictionary <string, List <CallbackVo> >();
            mDispatchDic = new Dictionary <string, bool>();
            mModifier    = new PropModifier();

            if (logger == null)
            {
                logger = new DefaultLogger("Dispatcher[" + name + "]");
            }
            mLogger = logger;
        }