@@ -21,7 +21,6 @@ use helix_view::{
2121 document::{Mode, SCRATCH_BUFFER_NAME},
2222 editor::CursorShapeConfig,
2323 graphics::{CursorKind, Modifier, Rect, Style},
24− info::Info,
2524 input::KeyEvent,
2625 keyboard::{KeyCode, KeyModifiers},
2726 Document, Editor, Theme, View,
@@ -37,7 +36,6 @@ pub struct EditorView {
3736 last_insert: (commands::MappableCommand, Vec<KeyEvent>),
3837 pub(crate) completion: Option<Completion>,
3938 spinners: ProgressSpinners,
40− autoinfo: Option<Info>,
4139}
4240
4341impl Default for EditorView {
@@ -54,7 +52,6 @@ impl EditorView {
5452 last_insert: (commands::MappableCommand::normal_mode, Vec::new()),
5553 completion: None,
5654 spinners: ProgressSpinners::default(),
57− autoinfo: None,
5855 }
5956 }
6057
@@ -678,13 +675,13 @@ impl EditorView {
678675 cxt: &mut commands::Context,
679676 event: KeyEvent,
680677 ) -> Option<KeymapResult> {
681− self.autoinfo = None;
678+ cxt.editor.autoinfo = None;
682679 let key_result = self.keymaps.get_mut(&mode).unwrap().get(event);
683− self.autoinfo = key_result.sticky.map(|node| node.infobox());
680+ cxt.editor.autoinfo = key_result.sticky.map(|node| node.infobox());
684681
685682 match &key_result.kind {
686683 KeymapResultKind::Matched(command) => command.execute(cxt),
687− KeymapResultKind::Pending(node) => self.autoinfo = Some(node.infobox()),
684+ KeymapResultKind::Pending(node) => cxt.editor.autoinfo = Some(node.infobox()),
688685 KeymapResultKind::MatchedSequence(commands) => {
689686 for command in commands {
690687 command.execute(cxt);
@@ -1093,8 +1090,9 @@ impl Component for EditorView {
10931090 }
10941091
10951092 if cx.editor.config.auto_info {
1096− if let Some(ref mut info) = self.autoinfo {
1093+ if let Some(mut info) = cx.editor.autoinfo.take() {
10971094 info.render(area, surface, cx);
1095+ cx.editor.autoinfo = Some(info)
10981096 }
10991097 }
11001098