示例#1
0
文件: FromEvent.cs 项目: ufcpp/UniRx
        protected override IDisposable SubscribeCore(IObserver <EventPattern <TEventArgs> > observer, IDisposable cancel)
        {
            var fe = new FromEventPattern(this, observer);

            return(fe.Register() ?  fe : Disposable.Empty);
        }
示例#2
0
        protected override IDisposable SubscribeCore(UniRx.IObserver <EventPattern <TEventArgs> > observer, IDisposable cancel)
        {
            FromEventPattern fromEventPattern = new FromEventPattern(this, observer);

            return((!fromEventPattern.Register()) ? Disposable.Empty : fromEventPattern);
        }