Ejemplo n.º 1
0
 public ClickerIntervalFactory(
     IDelayRangeProvider delayRangeProvider,
     IFixedDelayProvider fixedDelayProvider
     )
 {
     _delayRangeProvider = delayRangeProvider;
     _fixedDelayProvider = fixedDelayProvider;
 }
Ejemplo n.º 2
0
        public MainWindowViewModel(
            IEventBroker <ClickerEventArgs> eventBroker,
            ISubscribesContainer <ClickerEventArgs> subscribeContainer,
            IViewDispatcher dispatcher,
            IClickerFactory clickerFactory,
            IDelayRangeProvider delayRangeProvider,
            IAreaRectProvider areaRectProvider,
            IFixedDelayProvider fixedDelayProvider
            )
        {
            _eventBroker        = eventBroker ?? throw new NullReferenceException(nameof(eventBroker));
            _subscribeContainer = subscribeContainer ?? throw new NullReferenceException(nameof(subscribeContainer));
            _dispatcher         = dispatcher ?? throw new NullReferenceException(nameof(dispatcher));
            _clickerFactory     = clickerFactory ?? throw new NullReferenceException(nameof(clickerFactory));
            _delayRangeProvider = delayRangeProvider ?? throw new NullReferenceException(nameof(delayRangeProvider));
            _areaRectProvider   = areaRectProvider ?? throw new NullReferenceException(nameof(areaRectProvider));
            _fixedDelayProvider = fixedDelayProvider ?? throw new NullReferenceException(nameof(fixedDelayProvider));

            _deltaValue = Constants.DeltaValue;

            Init();
            Subscribe();
        }