public void SetTargetPort(PortModel port) { if (TargetPort == port) { return; } TargetPort?.RemoveLink(this); TargetPort = port; TargetPort.AddLink(this); TargetPortChanged?.Invoke(); }
public void SetTargetPort(PortModel?port) { if (TargetPort == port) { return; } var old = TargetPort; TargetPort?.RemoveLink(this); TargetPort = port; TargetPort?.AddLink(this); TargetPortChanged?.Invoke(this, old, TargetPort); }