aboutsummaryrefslogtreecommitdiff
path: root/vis-core.h
diff options
context:
space:
mode:
authorRandy Palamar <randy@rnpnr.xyz>2024-05-11 10:38:28 -0600
committerRandy Palamar <randy@rnpnr.xyz>2024-05-21 20:21:46 -0600
commit07b8e9d8a293d63fd9c1059968b53ad396e9f013 (patch)
tree8da02e24e203efbb8772fde0f0689aac87e31574 /vis-core.h
parentb7074021b7bfb0932b889b9560dd22df31cef818 (diff)
downloadvis-07b8e9d8a293d63fd9c1059968b53ad396e9f013.tar.gz
vis-07b8e9d8a293d63fd9c1059968b53ad396e9f013.tar.xz
cleanup vis event interface
This removes the function pointer interface which was adding needless complexity and making it difficult to add new events. Now if new events are only meant for lua they only need to be added to the lua interface. This will also have a minor reduction in runtime memory usage and produce a smaller binary. The only runtime difference is that QUIT happens after all windows have been closed and their files freed.
Diffstat (limited to 'vis-core.h')
-rw-r--r--vis-core.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/vis-core.h b/vis-core.h
index 4f81e4c..9746fc9 100644
--- a/vis-core.h
+++ b/vis-core.h
@@ -215,7 +215,6 @@ struct Vis {
Array actions_user; /* dynamically allocated editor actions */
lua_State *lua; /* lua context used for syntax highlighting */
enum TextLoadMethod load_method; /* how existing files should be loaded */
- VisEvent *event;
Array operators;
Array motions;
Array textobjects;
@@ -268,8 +267,9 @@ Mode *mode_get(Vis*, enum VisMode);
void mode_set(Vis *vis, Mode *new_mode);
Macro *macro_get(Vis *vis, enum VisRegister);
-void window_selection_save(Win *win);
Win *window_new_file(Vis*, File*, enum UiOption);
+void window_selection_save(Win *win);
+void window_status_update(Vis *vis, Win *win);
char *absolute_path(const char *path);