From 8a609047c3e0d9586038b04cebb288d62db57a18 Mon Sep 17 00:00:00 2001 From: Dmitry Sharshakov Date: Sun, 5 Sep 2021 08:50:03 +0300 Subject: Mouse command for editing logpoint --- helix-term/src/ui/editor.rs | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'helix-term/src/ui') diff --git a/helix-term/src/ui/editor.rs b/helix-term/src/ui/editor.rs index 20fdd152..b6757ca0 100644 --- a/helix-term/src/ui/editor.rs +++ b/helix-term/src/ui/editor.rs @@ -1077,6 +1077,7 @@ impl EditorView { kind: MouseEventKind::Up(MouseButton::Right), row, column, + modifiers, .. } => { let result = cxt.editor.tree.views().find_map(|(view, _focus)| { @@ -1090,7 +1091,11 @@ impl EditorView { let doc = &mut cxt.editor.documents[cxt.editor.tree.get(view_id).doc]; if let Ok(pos) = doc.text().try_line_to_char(line) { doc.set_selection(view_id, Selection::point(pos)); - commands::Command::dap_edit_condition.execute(cxt); + if modifiers == crossterm::event::KeyModifiers::ALT { + commands::Command::dap_edit_log.execute(cxt); + } else { + commands::Command::dap_edit_condition.execute(cxt); + } return EventResult::Consumed(None); } -- cgit v1.2.3-70-g09d2