void UpdatedAlphaCollection(AbstractAlpha alpha) { //call the event from the view model if (AlphaCollectionUpdated != null) { AlphaCollectionUpdated(alpha); } }
void OnAlphaRemoved(AbstractAlpha alpha) { this.Dispatcher.Invoke(DispatcherPriority.Render, new Action ( delegate() { AlphaCollection.Remove(alpha); })); }
void OnAlphaUpdated(AbstractAlpha alpha) { this.Dispatcher.Invoke(DispatcherPriority.Render, new Action ( delegate() { if (AlphaCollection.Where( c => c.SourceDataSet == alpha.SourceDataSet && c.AlphaFilter == alpha.AlphaFilter && c.Xaxis.BinWidth == alpha.Xaxis.BinWidth && c.Yaxis.BinWidth == alpha.Yaxis.BinWidth && c.Xaxis.AxisType == alpha.Xaxis.AxisType && c.Yaxis.AxisType == alpha.Yaxis.AxisType).Count() == 0) { AlphaCollection.Add(alpha); } })); }