/// <inheritdoc/> protected override void OnMouseDown(MouseButtonEventArgs e) { if (e.ChangedButton == MouseButton.Left && !e.Handled) { parent.JumpToReference(referenceSegment); e.Handled = true; } }
/// <inheritdoc/> protected override void OnMouseDown(MouseButtonEventArgs e) { // Only allow left click or ctrl + left click, nothing else. That way the user can eg. // hold down shift or alt or shift+ctrl etc and select text where a reference is located // without being taken to the definition. if (!e.Handled && e.ChangedButton == MouseButton.Left && (Keyboard.Modifiers == ModifierKeys.None || Keyboard.Modifiers == ModifierKeys.Control)) { parent.JumpToReference(referenceSegment, e); } }