diff options
author | James Booth <boothj5@gmail.com> | 2015-01-15 00:02:42 +0000 |
---|---|---|
committer | James Booth <boothj5@gmail.com> | 2015-01-15 00:02:42 +0000 |
commit | db9a2cf0ab40912d1d342b8ad3dfacbf8776411a (patch) | |
tree | e1ff8fed39b1aa90cd5617281458fd44bdda6810 /src/ui | |
parent | 3984c660b6c46533de5b03fd4ae583b68778bff7 (diff) | |
download | profani-tty-db9a2cf0ab40912d1d342b8ad3dfacbf8776411a.tar.gz |
Inlined ui_handle_special_keys
Diffstat (limited to 'src/ui')
-rw-r--r-- | src/ui/core.c | 18 | ||||
-rw-r--r-- | src/ui/ui.h | 1 |
2 files changed, 6 insertions, 13 deletions
diff --git a/src/ui/core.c b/src/ui/core.c index 855c600c..5b621ba1 100644 --- a/src/ui/core.c +++ b/src/ui/core.c @@ -179,6 +179,12 @@ ui_get_char(char *input, int *size) { int result = 0; wint_t ch = inp_get_char(input, size, &result); + _win_handle_switch(ch); + _win_handle_page(ch, result); + if (ch == KEY_RESIZE) { + ui_resize(); + } + if (ch != ERR && result != ERR) { ui_reset_idle_time(); ui_input_nonblocking(TRUE); @@ -186,8 +192,6 @@ ui_get_char(char *input, int *size) ui_input_nonblocking(FALSE); } - ui_handle_special_keys(ch, result); - return ch; } @@ -705,16 +709,6 @@ ui_disconnected(void) } void -ui_handle_special_keys(const wint_t ch, const int result) -{ - _win_handle_switch(ch); - _win_handle_page(ch, result); - if (ch == KEY_RESIZE) { - ui_resize(); - } -} - -void ui_close_connected_win(int index) { ProfWin *window = wins_get_by_num(index); diff --git a/src/ui/ui.h b/src/ui/ui.h index 600f7fe0..8c9690d6 100644 --- a/src/ui/ui.h +++ b/src/ui/ui.h @@ -61,7 +61,6 @@ void ui_close(void); void ui_redraw(void); void ui_resize(void); GSList* ui_get_chat_recipients(void); -void ui_handle_special_keys(const wint_t ch, const int result); gboolean ui_switch_win(const int i); void ui_next_win(void); void ui_previous_win(void); |