From c6fc0033e1bf8aa1deb2c44284049041766361f8 Mon Sep 17 00:00:00 2001 From: Mikkel Oscar Lyderik Date: Sun, 24 Jan 2016 02:19:08 +0100 Subject: swaybar: move core functionality to state.c --- swaybar/state.h | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) (limited to 'swaybar/state.h') diff --git a/swaybar/state.h b/swaybar/state.h index e09807d0..985002f8 100644 --- a/swaybar/state.h +++ b/swaybar/state.h @@ -33,9 +33,14 @@ struct workspace { }; /** - * Initialize state. + * Setup state. */ -struct swaybar_state *init_state(); +void state_setup(struct swaybar_state *state, const char *socket_path, const char *bar_id, int desired_output); + +/** + * State mainloop. + */ +void state_run(struct swaybar_state *state); /** * free workspace list. @@ -43,8 +48,8 @@ struct swaybar_state *init_state(); void free_workspaces(list_t *workspaces); /** - * Free state struct. + * Teardown state. */ -void free_state(struct swaybar_state *state); +void state_teardown(struct swaybar_state *state); #endif /* _SWAYBAR_STATE_H */ -- cgit v1.2.3