private void Marker2Tb_KeyDown(object sender, KeyEventArgs e) { if (Validation.GetHasError(Marker2Tb)) { return; } if (e.Key == Key.Return) { try { var res = (int)uint.Parse(Marker2Tb.Text); if (res > Maximum) { res = Maximum; } Marker2 = res; if (MoveMarker2 != null) { MoveMarker2.Invoke(Marker2); } } catch { Marker2Tb.Text = Marker2.ToString(CultureInfo.InvariantCulture); } } }
private void RaiseMoveMarker2() { if (MoveMarker2 != null) { MoveMarker2.Invoke(); } }