Exemple #1
0
        public void StartCountdown(double seconds)
        {
            IObservable <long> obs = Extensions.ObservableExtensions.CountDown(seconds);

            _rTSSService.SetIsCaptureTimerActive(true);

            SetCaptureTimerValue(0);
            _disposableCountdown?.Dispose();
            _disposableCountdown = obs.Subscribe(t =>
            {
                SetCaptureTimerValue((int)t);
                _rTSSService.Refresh();

                if (t == 0)
                {
                    _rTSSService.SetIsCaptureTimerActive(false);
                }
            });
        }