public RawLineViewModel(RawLine2D rawLine2D, ProfileEditorViewModel.AxisSystem axisSystem, ProfileEditorViewModel parent) : base(rawLine2D, axisSystem, parent) { _rawLine = rawLine2D; X = new RawInputViewModel(_rawLine.X, this); Angle = new RawInputViewModel(_rawLine.Angle, this); Y = new RawInputViewModel(_rawLine.Y, this); DeltaX = new RawInputViewModel(_rawLine.DeltaX, this); DeltaY = new RawInputViewModel(_rawLine.DeltaY, this); Chamfer = new RawInputViewModel(_rawLine.Chamfer, this); EndRadius = new RawInputViewModel(_rawLine.EndRadius, this); foreach (var rawInputViewModel in InputVmList) { rawInputViewModel.OnSourceUpdated += RawLine_SourceUpdated; } //Angle.OnSourceUpdated += RawLine_SourceUpdated; //X.OnSourceUpdated += RawLine_SourceUpdated; //Y.OnSourceUpdated += RawLine_SourceUpdated; //DeltaX.OnSourceUpdated += RawLine_SourceUpdated; //DeltaY.OnSourceUpdated += RawLine_SourceUpdated; //Chamfer.OnSourceUpdated += RawLine_SourceUpdated; //EndRadius.OnSourceUpdated += RawLine_SourceUpdated; }
public RawArcViewModel(RawArc2D rawLine2D, ProfileEditorViewModel.AxisSystem axisSystem, ProfileEditorViewModel parent) : base(rawLine2D, axisSystem, parent) { _rawArc = rawLine2D; X = new RawInputViewModel(_rawArc.X, this); Y = new RawInputViewModel(_rawArc.Y, this); CenterX = new RawInputViewModel(_rawArc.CenterX, this); CenterY = new RawInputViewModel(_rawArc.CenterY, this); DeltaX = new RawInputViewModel(_rawArc.DeltaX, this); DeltaY = new RawInputViewModel(_rawArc.DeltaY, this); Chamfer = new RawInputViewModel(_rawArc.Chamfer, this); Radius = new RawInputViewModel(_rawArc.Radius, this); EndRadius = new RawInputViewModel(_rawArc.EndRadius, this); foreach (var rawInputViewModel in InputVmList) { rawInputViewModel.OnSourceUpdated += RawLine_SourceUpdated; } //X.OnSourceUpdated += RawLine_SourceUpdated; //Y.OnSourceUpdated += RawLine_SourceUpdated; //DeltaX.OnSourceUpdated += RawLine_SourceUpdated; //DeltaY.OnSourceUpdated += RawLine_SourceUpdated; //Chamfer.OnSourceUpdated += RawLine_SourceUpdated; //Radius.OnSourceUpdated += RawLine_SourceUpdated; //EndRadius.OnSourceUpdated += RawLine_SourceUpdated; }
/* * la gestione del axisLabel può essere raggruppata in classe abstract */ public RawInitPointViewModel(RawInitPoint2D rawPoint2D, ProfileEditorViewModel.AxisSystem axisSystem, ProfileEditorViewModel parent) : base(rawPoint2D, axisSystem, parent) { _rawPoint2D = rawPoint2D; X = new RawInputViewModel(_rawPoint2D.X); Y = new RawInputViewModel(_rawPoint2D.Y); X.OnSourceUpdated += RawLine_SourceUpdated; Y.OnSourceUpdated += RawLine_SourceUpdated; }
internal void AddToUpdateList(RawInputViewModel rawInputViewModel) { InputVmList.Add(rawInputViewModel); }