From 3eda85a13268a7ceeb97d2e6666f0c5e6e5942d4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marc=20Andr=C3=A9=20Tanner?= Date: Sun, 25 Oct 2015 21:49:01 +0100 Subject: vis: introduce vis_motion_type API --- vis.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'vis.c') diff --git a/vis.c b/vis.c index 5ea6715..f162723 100644 --- a/vis.c +++ b/vis.c @@ -908,7 +908,7 @@ static const char *gotoline(Vis *vis, const char *keys, const Arg *arg) { } static const char *motiontype(Vis *vis, const char *keys, const Arg *arg) { - vis->action.type = arg->i; + vis_motion_type(vis, arg->i); return keys; } @@ -2888,3 +2888,7 @@ void vis_mark_set(Vis *vis, enum VisMark mark, size_t pos) { if (mark < LENGTH(file->marks)) file->marks[mark] = text_mark_set(file->text, pos); } + +void vis_motion_type(Vis *vis, enum VisMotionType type) { + vis->action.type = type; +} -- cgit v1.2.3