diff options
| author | Ken Raeburn | 2015-10-02 05:00:23 -0400 |
|---|---|---|
| committer | Ken Raeburn | 2015-10-11 01:15:12 -0400 |
| commit | fcb5d3e8b158f7ea8492aa14f79804fae18e76f9 (patch) | |
| tree | 0e0429c3a6242ca93628c5b7490ef28a94db99f1 /src/xterm.h | |
| parent | 5504ede9518053e619b2cc4bb01ce6eff254d3c8 (diff) | |
| download | emacs-fcb5d3e8b158f7ea8492aa14f79804fae18e76f9.tar.gz emacs-fcb5d3e8b158f7ea8492aa14f79804fae18e76f9.zip | |
Add x_catch_errors_with_handler.
* src/xterm.c (struct x_error_message_stack): Add new fields for a
callback function and associated data pointer.
(x_error_catcher): If the callback function is set, call it after
saving the error message string.
(x_catch_errors_with_handler): Renamed from x_catch_errors but now
accepts a callback function and data pointer.
(x_catch_errors): Now a wrapper function.
* src/xterm.h (x_special_error_handler): New typedef.
(x_catch_errors_with_handler): Declare.
Diffstat (limited to 'src/xterm.h')
| -rw-r--r-- | src/xterm.h | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/xterm.h b/src/xterm.h index fe3455ff7ce..f7d2803ff29 100644 --- a/src/xterm.h +++ b/src/xterm.h | |||
| @@ -1024,8 +1024,13 @@ XrmDatabase x_load_resources (Display *, const char *, const char *, | |||
| 1024 | 1024 | ||
| 1025 | /* Defined in xterm.c */ | 1025 | /* Defined in xterm.c */ |
| 1026 | 1026 | ||
| 1027 | typedef void (*x_special_error_handler)(Display *, XErrorEvent *, char *, | ||
| 1028 | void *); | ||
| 1029 | |||
| 1027 | extern bool x_text_icon (struct frame *, const char *); | 1030 | extern bool x_text_icon (struct frame *, const char *); |
| 1028 | extern void x_catch_errors (Display *); | 1031 | extern void x_catch_errors (Display *); |
| 1032 | extern void x_catch_errors_with_handler (Display *, x_special_error_handler, | ||
| 1033 | void *); | ||
| 1029 | extern void x_check_errors (Display *, const char *) | 1034 | extern void x_check_errors (Display *, const char *) |
| 1030 | ATTRIBUTE_FORMAT_PRINTF (2, 0); | 1035 | ATTRIBUTE_FORMAT_PRINTF (2, 0); |
| 1031 | extern bool x_had_errors_p (Display *); | 1036 | extern bool x_had_errors_p (Display *); |