diff options
-rw-r--r-- | core/events.lua | 3 | ||||
-rw-r--r-- | src/textadept.c | 1 |
2 files changed, 3 insertions, 1 deletions
diff --git a/core/events.lua b/core/events.lua index 5b7e92fd..144917a7 100644 --- a/core/events.lua +++ b/core/events.lua @@ -119,7 +119,8 @@ local M = {} -- * _`next`_: Whether or not to search forward. -- @field FOCUS (string) -- Emitted when Textadept receives focus. --- This event is never emitted when Textadept is running in the terminal. +-- In the terminal, this event is only emitted after resuming from a suspended +-- state. -- @field HOTSPOT_CLICK (string) -- Emitted when clicking on text that is in a style that has the hotspot -- attribute set. diff --git a/src/textadept.c b/src/textadept.c index 3061b256..1b1dad0e 100644 --- a/src/textadept.c +++ b/src/textadept.c @@ -2387,6 +2387,7 @@ static void t_signal(int signal) { resizeterm(w.ws_row, w.ws_col), pane_resize(pane, LINES - 2, COLS, 1, 0); WINDOW *ce_win = scintilla_get_window(command_entry); wresize(ce_win, 1, COLS), mvwin(ce_win, LINES - 1 - getmaxy(ce_win), 0); + if (signal == SIGCONT) lL_event(lua, "focus", -1); lL_event(lua, "update_ui", -1); refresh_all(); } else endwin(), termkey_stop(ta_tk), kill(0, SIGSTOP); |