diff options
| author | Marc André Tanner <mat@brain-dump.org> | 2015-11-07 08:51:26 +0100 |
|---|---|---|
| committer | Marc André Tanner <mat@brain-dump.org> | 2015-11-07 12:16:34 +0100 |
| commit | 26b56bc3090e9ad6ffd71f216a53805c5e894807 (patch) | |
| tree | 48f4d26dd01571df196bd1ee2228c3d72e65581b /vis-modes.c | |
| parent | f1002cdc6d70bae0c5f68df1d91cd170189d4789 (diff) | |
| download | vis-26b56bc3090e9ad6ffd71f216a53805c5e894807.tar.gz vis-26b56bc3090e9ad6ffd71f216a53805c5e894807.tar.xz | |
vis: API documentation and cleanup
Diffstat (limited to 'vis-modes.c')
| -rw-r--r-- | vis-modes.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/vis-modes.c b/vis-modes.c index 7d2f7e5..b53aeb7 100644 --- a/vis-modes.c +++ b/vis-modes.c @@ -20,13 +20,13 @@ void mode_set(Vis *vis, Mode *new_mode) { vis->win->ui->draw_status(vis->win->ui); } -static bool mode_map(Mode *mode, const char *name, KeyBinding *binding) { - return map_put(mode->bindings, name, binding); +static bool mode_map(Mode *mode, const char *key, KeyBinding *binding) { + return map_put(mode->bindings, key, binding); } -bool vis_mode_map(Vis *vis, enum VisMode modeid, const char *name, KeyBinding *binding) { +bool vis_mode_map(Vis *vis, enum VisMode modeid, const char *key, KeyBinding *binding) { Mode *mode = mode_get(vis, modeid); - return mode && map_put(mode->bindings, name, binding); + return mode && mode_map(mode, key, binding); } bool vis_mode_bindings(Vis *vis, enum VisMode modeid, KeyBinding **bindings) { @@ -41,9 +41,9 @@ bool vis_mode_bindings(Vis *vis, enum VisMode modeid, KeyBinding **bindings) { return success; } -bool vis_mode_unmap(Vis *vis, enum VisMode modeid, const char *name) { +bool vis_mode_unmap(Vis *vis, enum VisMode modeid, const char *key) { Mode *mode = mode_get(vis, modeid); - return mode && map_delete(mode->bindings, name); + return mode && map_delete(mode->bindings, key); } /** mode switching event handlers */ |
