public IntervalPageViewModel() { HasStarted = false; RemainingTime = TimeSpan.FromSeconds(0); Blocks = new ObservableCollection <IntervalBlock>(); _dispatcherTimer = new DispatcherTimer(); _dispatcherTimer.Tick += Tick; _dispatcherTimer.Interval = TimeSpan.FromMilliseconds(100); _elapsedTime = TimeSpan.FromSeconds(0); ButtonStartStopText = AppResources.ButtonStart; ButtonStartStopBackground = Common.GreenColorBrush; _intervalBlockStorage = IntervalBlockStore.Prepare(); }
public StoredIntervalBlockViewModel() { IntervalBlockStore = IntervalBlockStore.Prepare(); BlockCollection = new ObservableCollection <IntervalBlockItem>(IntervalBlockStore.Items); }