Commit 6ee327d8 authored by YAMAMOTO Mitsuharu's avatar YAMAMOTO Mitsuharu

Add handle_user_signal_hook

* src/keyboard.h (handle_user_signal_hook): New declaration.
* src/keyboard.c (handle_user_signal_hook): New variable.
(handle_user_signal): Call it.
parent 47580e0d
......@@ -7124,6 +7124,9 @@ struct user_signal_info
/* List of user signals. */
static struct user_signal_info *user_signals = NULL;
/* Function called when handling user signals. */
void (*handle_user_signal_hook) (int);
void
add_user_signal (int sig, const char *name)
{
......@@ -7172,6 +7175,8 @@ handle_user_signal (int sig)
}
p->npending++;
if (handle_user_signal_hook)
(*handle_user_signal_hook) (sig);
#ifdef USABLE_SIGIO
if (interrupt_input)
handle_input_available_signal (sig);
......
......@@ -415,6 +415,8 @@ extern void unuse_menu_items (void);
#define EVENT_HEAD_KIND(event_head) \
(Fget ((event_head), Qevent_kind))
extern void (*handle_user_signal_hook) (int);
/* True while doing kbd input. */
extern bool waiting_for_input;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment