diff options
author | nicm <nicm> | 2017-05-17 15:20:23 +0000 |
---|---|---|
committer | nicm <nicm> | 2017-05-17 15:20:23 +0000 |
commit | 91d202da7ed9d63b481e03e02567775d87a90e0e (patch) | |
tree | f84c1ed0754eead05f4a4b11524cdb38220a4501 /tmux.h | |
parent | 31625c2d171080aea53baee7c0aec7e9f939cf7d (diff) | |
download | rtmux-91d202da7ed9d63b481e03e02567775d87a90e0e.tar.gz rtmux-91d202da7ed9d63b481e03e02567775d87a90e0e.tar.bz2 rtmux-91d202da7ed9d63b481e03e02567775d87a90e0e.zip |
Tidy command prompt callbacks and pass in the client.
Diffstat (limited to 'tmux.h')
-rw-r--r-- | tmux.h | 11 |
1 files changed, 7 insertions, 4 deletions
@@ -1284,6 +1284,8 @@ struct cmd_entry { }; /* Client connection. */ +typedef int (*prompt_input_cb)(struct client *, void *, const char *, int); +typedef void (*prompt_free_cb)(void *); struct client { const char *name; struct tmuxpeer *peer; @@ -1353,7 +1355,8 @@ struct client { struct key_table *keytable; struct event identify_timer; - void (*identify_callback)(struct client *, struct window_pane *); + void (*identify_callback)(struct client *, + struct window_pane *); void *identify_callback_data; char *message_string; @@ -1364,8 +1367,8 @@ struct client { char *prompt_string; struct utf8_data *prompt_buffer; size_t prompt_index; - int (*prompt_callbackfn)(void *, const char *, int); - void (*prompt_freefn)(void *); + prompt_input_cb prompt_inputcb; + prompt_free_cb prompt_freecb; void *prompt_data; u_int prompt_hindex; enum { PROMPT_ENTRY, PROMPT_COMMAND } prompt_mode; @@ -1889,7 +1892,7 @@ void printflike(2, 3) status_message_set(struct client *, const char *, ...); void status_message_clear(struct client *); int status_message_redraw(struct client *); void status_prompt_set(struct client *, const char *, const char *, - int (*)(void *, const char *, int), void (*)(void *), void *, int); + prompt_input_cb, prompt_free_cb, void *, int); void status_prompt_clear(struct client *); int status_prompt_redraw(struct client *); int status_prompt_key(struct client *, key_code); |