From 87d81f090d83c5e3aa6866e34575e55a23241b37 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marc=20Andr=C3=A9=20Tanner?= Date: Thu, 29 Dec 2016 22:50:13 +0100 Subject: vis: support count for macro replay Fix #448 --- vis.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'vis.c') diff --git a/vis.c b/vis.c index ab2f244..b67e660 100644 --- a/vis.c +++ b/vis.c @@ -1267,7 +1267,10 @@ bool vis_macro_replay(Vis *vis, enum VisRegister id) { Macro *macro = macro_get(vis, id); if (!macro || macro == vis->recording) return false; - macro_replay(vis, macro); + int count = vis_count_get_default(vis, 1); + vis_cancel(vis); + for (int i = 0; i < count; i++) + macro_replay(vis, macro); vis_file_snapshot(vis, vis->win->file); return true; } -- cgit v1.2.3