mirror of
https://github.com/helix-editor/helix.git
synced 2024-11-22 09:26:19 +04:00
respect count for repeating motion (#3057)
This commit is contained in:
parent
3cced1e3c8
commit
e6a6e251c5
@ -1224,9 +1224,12 @@ fn extend_prev_char(cx: &mut Context) {
|
||||
}
|
||||
|
||||
fn repeat_last_motion(cx: &mut Context) {
|
||||
let count = cx.count();
|
||||
let last_motion = cx.editor.last_motion.take();
|
||||
if let Some(m) = &last_motion {
|
||||
m.run(cx.editor);
|
||||
for _ in 0..count {
|
||||
m.run(cx.editor);
|
||||
}
|
||||
cx.editor.last_motion = last_motion;
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user