diff options
Diffstat (limited to 'helix-view/src/editor.rs')
-rw-r--r-- | helix-view/src/editor.rs | 23 |
1 files changed, 22 insertions, 1 deletions
diff --git a/helix-view/src/editor.rs b/helix-view/src/editor.rs index 90e3bf47..60864e9e 100644 --- a/helix-view/src/editor.rs +++ b/helix-view/src/editor.rs @@ -7,7 +7,11 @@ use crate::{ }; use futures_util::future; +use futures_util::stream::select_all::SelectAll; +use tokio_stream::wrappers::UnboundedReceiverStream; + use std::{ + collections::HashMap, path::{Path, PathBuf}, pin::Pin, sync::Arc, @@ -21,8 +25,9 @@ use anyhow::Error; pub use helix_core::diagnostic::Severity; pub use helix_core::register::Registers; -use helix_core::syntax; +use helix_core::syntax::{self, DebugConfigCompletion}; use helix_core::Position; +use helix_dap as dap; use serde::Deserialize; @@ -100,6 +105,15 @@ pub struct Editor { pub registers: Registers, pub theme: Theme, pub language_servers: helix_lsp::Registry, + + pub debugger: Option<dap::Client>, + pub debugger_events: SelectAll<UnboundedReceiverStream<dap::Payload>>, + pub breakpoints: HashMap<PathBuf, Vec<dap::SourceBreakpoint>>, + pub debug_config_picker: Option<Vec<String>>, + pub debug_config_completions: Option<Vec<Vec<DebugConfigCompletion>>>, + pub variables: Option<Vec<String>>, + pub variables_page: usize, + pub clipboard_provider: Box<dyn ClipboardProvider>, pub syn_loader: Arc<syntax::Loader>, @@ -139,6 +153,13 @@ impl Editor { selected_register: None, theme: themes.default(), language_servers, + debugger: None, + debugger_events: SelectAll::new(), + breakpoints: HashMap::new(), + debug_config_picker: None, + debug_config_completions: None, + variables: None, + variables_page: 0, syn_loader: config_loader, theme_loader: themes, registers: Registers::default(), |