aboutsummaryrefslogtreecommitdiff
path: root/helix-term/src
diff options
context:
space:
mode:
Diffstat (limited to 'helix-term/src')
-rw-r--r--helix-term/src/commands/dap.rs12
1 files changed, 11 insertions, 1 deletions
diff --git a/helix-term/src/commands/dap.rs b/helix-term/src/commands/dap.rs
index bb92b3ac..6da6cc81 100644
--- a/helix-term/src/commands/dap.rs
+++ b/helix-term/src/commands/dap.rs
@@ -102,10 +102,20 @@ fn thread_picker(cx: &mut Context, callback_fn: impl Fn(&mut Editor, &dap::Threa
return;
}
+ let thread_states = debugger.thread_states.clone();
let picker = Picker::new(
true,
threads,
- |thread| thread.name.clone().into(), // TODO: include thread_states in the label
+ move |thread| {
+ format!(
+ "{} ({})",
+ thread.name,
+ thread_states
+ .get(&thread.id)
+ .unwrap_or(&"unknown".to_owned())
+ )
+ .into()
+ },
move |editor, thread, _action| callback_fn(editor, thread),
);
cx.push_layer(Box::new(picker))