protected async Task UpdateBins() { await Task.Run(() => { FreqBins.Refresh(); CallDurationBins.Refresh(); IntensityBins.Refresh(); TimeBins.Refresh(); }); OnPropertyChanged(nameof(FilterText)); }
public override async Task Initialize() { if (ParentViewModel != null) { IEnumerable <BatCall> batCalls = ParentViewModel.BatCalls; await Task.Run(() => { FreqBins.LoadBins(batCalls); IntensityBins.LoadBins(batCalls); CallDurationBins.LoadBins(batCalls); TimeBins.LoadBins(batCalls); }); FrequencyRange.Set(FreqBins.Range); IntensityRange.Set(IntensityBins.Range); DurationRange.Set(CallDurationBins.Range); TimeRange.Set(TimeBins.Range); Freq = new ObservableCollection <KeyValuePair <DateTime, uint> >(batCalls.Select(c => new KeyValuePair <DateTime, uint>(c.StartTime, c.MaxFrequency))); OnPropertyChanged(nameof(Freq)); OnPropertyChanged(nameof(FilterText)); } }