Example #1
0
 public uint Register(ICancelDelegate callback)
 {
     if (ValueContainer != null)
     {
         callback.Invoke(ValueContainer);
         return(0);
     }
     checked
     {
         uint order = ++_registeredCount;
         _registeredCallbacks.Add(new RegisteredDelegate(order, callback));
         return(order);
     }
 }
Example #2
0
 public RegisteredDelegate(uint order, ICancelDelegate callback)
 {
     this.callback = callback;
     this.order    = order;
 }