diff options
Diffstat (limited to 'vis.c')
| -rw-r--r-- | vis.c | 14 |
1 files changed, 9 insertions, 5 deletions
@@ -727,11 +727,7 @@ static const char *suspend(Vis *vis, const char *keys, const Arg *arg) { } static const char *repeat(Vis *vis, const char *keys, const Arg *arg) { - int count = vis->action.count; - vis->action = vis->action_prev; - if (count) - vis->action.count = count; - action_do(vis, &vis->action); + vis_repeat(vis); return keys; } @@ -2835,3 +2831,11 @@ bool vis_macro_replay(Vis *vis, enum VisMacro id) { buffer_release(&buf); return true; } + +void vis_repeat(Vis *vis) { + int count = vis->action.count; + vis->action = vis->action_prev; + if (count) + vis->action.count = count; + action_do(vis, &vis->action); +} |
