mirror of
https://github.com/sxyazi/yazi.git
synced 2026-07-21 23:01:05 +00:00
15 lines
257 B
Rust
15 lines
257 B
Rust
use yazi_shared::{event::Exec, render};
|
|
|
|
use crate::input::{Input, InputMode};
|
|
|
|
impl Input {
|
|
pub fn undo(&mut self, _: &Exec) {
|
|
if !self.snaps.undo() {
|
|
return;
|
|
}
|
|
if self.snap().mode == InputMode::Insert {
|
|
self.escape(());
|
|
}
|
|
render!();
|
|
}
|
|
}
|