@@ -6,7 +6,7 @@ use crossterm::event::Event;
66use helix_core::Position;
77use tui::{buffer::Buffer as Surface, layout::Rect};
88
9−pub type Callback = Box<dyn FnOnce(&mut Compositor, &mut Editor)>;
9+pub type Callback = Box<dyn FnOnce(&mut Compositor)>;
1010
1111// --> EventResult should have a callback that takes a context with methods like .popup(),
1212// .prompt() etc. That way we can abstract it from the renderer.
@@ -22,7 +22,7 @@ pub enum EventResult {
2222 Consumed(Option<Callback>),
2323}
2424
25−use helix_view::{Editor, View};
25+use helix_view::Editor;
2626
2727use crate::application::LspCallbacks;
2828
@@ -111,7 +111,7 @@ impl Compositor {
111111 for layer in self.layers.iter_mut().rev() {
112112 match layer.handle_event(event, cx) {
113113 EventResult::Consumed(Some(callback)) => {
114− callback(self, cx.editor);
114+ callback(self);
115115 return true;
116116 }
117117 EventResult::Consumed(None) => return true,