fix: When cycling through prompt history, update event needs to trigger
This commit is contained in:
parent
2cee0c58ba
commit
1066b081dd
1 changed files with 2 additions and 0 deletions
|
@ -501,6 +501,7 @@ impl Component for Prompt {
|
||||||
if let Some(register) = self.history_register {
|
if let Some(register) = self.history_register {
|
||||||
let register = cx.editor.registers.get_mut(register);
|
let register = cx.editor.registers.get_mut(register);
|
||||||
self.change_history(register.read(), CompletionDirection::Backward);
|
self.change_history(register.read(), CompletionDirection::Backward);
|
||||||
|
(self.callback_fn)(cx, &self.line, PromptEvent::Update);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
KeyEvent {
|
KeyEvent {
|
||||||
|
@ -514,6 +515,7 @@ impl Component for Prompt {
|
||||||
if let Some(register) = self.history_register {
|
if let Some(register) = self.history_register {
|
||||||
let register = cx.editor.registers.get_mut(register);
|
let register = cx.editor.registers.get_mut(register);
|
||||||
self.change_history(register.read(), CompletionDirection::Forward);
|
self.change_history(register.read(), CompletionDirection::Forward);
|
||||||
|
(self.callback_fn)(cx, &self.line, PromptEvent::Update);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
KeyEvent {
|
KeyEvent {
|
||||||
|
|
Loading…
Add table
Reference in a new issue