Пример #1
0
        public static EventSignal <TArg> operator +(EventSignal <TArg> s, EventSignalHandler handler)
        {
            if (s == null)
            {
                s = new EventSignal <TArg>();
            }

            s.Add(handler);
            return(s);
        }
Пример #2
0
        public static EventSignal <TArg> operator +(EventSignal <TArg> s, Action <object> handler)
        {
            if (s == null)
            {
                s = new EventSignal <TArg>();
            }

            var deh = new DelegateEventHandler(handler);

            s.Add(deh);
            return(s);
        }