diff options
| author | Chong Yidong | 2006-02-27 03:35:31 +0000 |
|---|---|---|
| committer | Chong Yidong | 2006-02-27 03:35:31 +0000 |
| commit | 4545fa2085b65a310e46b6d599d3998e0a1fe370 (patch) | |
| tree | 51285cbdbd8cec969e859b17827f6d21572d0357 /src | |
| parent | c50a2aa68292912f11d951bf20b24d79533e0537 (diff) | |
| download | emacs-4545fa2085b65a310e46b6d599d3998e0a1fe370.tar.gz emacs-4545fa2085b65a310e46b6d599d3998e0a1fe370.zip | |
* xterm.h, xterm.c (x_uncatch_errors): Delete unneccessary
argument.
* xterm.c: (x_load_font, x_term_init, XTmouse_position)
(handle_one_xevent, x_connection_closed, x_list_fonts): No arg for
x_uncatch_errors.
* xselect.c (x_own_selection, x_decline_selection_request)
(x_reply_selection_request, x_get_foreign_selection)
(Fx_get_atom_name, Fx_send_client_event): Likewise.
* xfns.c (x_real_positions, x_set_mouse_color, Fx_focus_frame):
Likewise.
Diffstat (limited to 'src')
| -rw-r--r-- | src/ChangeLog | 18 | ||||
| -rw-r--r-- | src/xfns.c | 6 | ||||
| -rw-r--r-- | src/xselect.c | 12 | ||||
| -rw-r--r-- | src/xterm.c | 27 | ||||
| -rw-r--r-- | src/xterm.h | 4 |
5 files changed, 40 insertions, 27 deletions
diff --git a/src/ChangeLog b/src/ChangeLog index f8b34eb6192..79db6d09d0b 100644 --- a/src/ChangeLog +++ b/src/ChangeLog | |||
| @@ -1,3 +1,19 @@ | |||
| 1 | 2006-02-26 Chong Yidong <cyd@stupidchicken.com> | ||
| 2 | |||
| 3 | * xterm.h, xterm.c (x_uncatch_errors): Delete unneccessary | ||
| 4 | argument. | ||
| 5 | |||
| 6 | * xterm.c: (x_load_font, x_term_init, XTmouse_position) | ||
| 7 | (handle_one_xevent, x_connection_closed, x_list_fonts): No arg for | ||
| 8 | x_uncatch_errors. | ||
| 9 | |||
| 10 | * xselect.c (x_own_selection, x_decline_selection_request) | ||
| 11 | (x_reply_selection_request, x_get_foreign_selection) | ||
| 12 | (Fx_get_atom_name, Fx_send_client_event): Likewise. | ||
| 13 | |||
| 14 | * xfns.c (x_real_positions, x_set_mouse_color, Fx_focus_frame): | ||
| 15 | Likewise. | ||
| 16 | |||
| 1 | 2006-02-26 Luc Teirlinck <teirllm@auburn.edu> | 17 | 2006-02-26 Luc Teirlinck <teirllm@auburn.edu> |
| 2 | 18 | ||
| 3 | * lread.c: Declare Vload_file_rep_suffixes instead of | 19 | * lread.c: Declare Vload_file_rep_suffixes instead of |
| @@ -28,7 +44,7 @@ | |||
| 28 | 2006-02-25 Chong Yidong <cyd@stupidchicken.com> | 44 | 2006-02-25 Chong Yidong <cyd@stupidchicken.com> |
| 29 | 45 | ||
| 30 | * xterm.h (x_catch_errors) Return value changed to void. | 46 | * xterm.h (x_catch_errors) Return value changed to void. |
| 31 | (x_uncatch_errors): Delete unused count argument delete. | 47 | (x_uncatch_errors): Delete unused count argument. |
| 32 | 48 | ||
| 33 | * xterm.c (x_catch_errors): Don't use record_unwind_protect, since | 49 | * xterm.c (x_catch_errors): Don't use record_unwind_protect, since |
| 34 | it can be called in a signal handler. | 50 | it can be called in a signal handler. |
diff --git a/src/xfns.c b/src/xfns.c index a65cf31a360..ede53262f5f 100644 --- a/src/xfns.c +++ b/src/xfns.c | |||
| @@ -666,7 +666,7 @@ x_real_positions (f, xptr, yptr) | |||
| 666 | had_errors = x_had_errors_p (FRAME_X_DISPLAY (f)); | 666 | had_errors = x_had_errors_p (FRAME_X_DISPLAY (f)); |
| 667 | } | 667 | } |
| 668 | 668 | ||
| 669 | x_uncatch_errors (FRAME_X_DISPLAY (f)); | 669 | x_uncatch_errors (); |
| 670 | 670 | ||
| 671 | UNBLOCK_INPUT; | 671 | UNBLOCK_INPUT; |
| 672 | 672 | ||
| @@ -1021,7 +1021,7 @@ x_set_mouse_color (f, arg, oldval) | |||
| 1021 | 1021 | ||
| 1022 | /* Check and report errors with the above calls. */ | 1022 | /* Check and report errors with the above calls. */ |
| 1023 | x_check_errors (dpy, "can't set cursor shape: %s"); | 1023 | x_check_errors (dpy, "can't set cursor shape: %s"); |
| 1024 | x_uncatch_errors (dpy); | 1024 | x_uncatch_errors (); |
| 1025 | 1025 | ||
| 1026 | { | 1026 | { |
| 1027 | XColor fore_color, back_color; | 1027 | XColor fore_color, back_color; |
| @@ -3443,7 +3443,7 @@ FRAME nil means use the selected frame. */) | |||
| 3443 | x_catch_errors (dpy); | 3443 | x_catch_errors (dpy); |
| 3444 | XSetInputFocus (FRAME_X_DISPLAY (f), FRAME_X_WINDOW (f), | 3444 | XSetInputFocus (FRAME_X_DISPLAY (f), FRAME_X_WINDOW (f), |
| 3445 | RevertToParent, CurrentTime); | 3445 | RevertToParent, CurrentTime); |
| 3446 | x_uncatch_errors (dpy); | 3446 | x_uncatch_errors (); |
| 3447 | UNBLOCK_INPUT; | 3447 | UNBLOCK_INPUT; |
| 3448 | 3448 | ||
| 3449 | return Qnil; | 3449 | return Qnil; |
diff --git a/src/xselect.c b/src/xselect.c index 6efa625543e..a0b4b091805 100644 --- a/src/xselect.c +++ b/src/xselect.c | |||
| @@ -410,7 +410,7 @@ x_own_selection (selection_name, selection_value) | |||
| 410 | x_catch_errors (display); | 410 | x_catch_errors (display); |
| 411 | XSetSelectionOwner (display, selection_atom, selecting_window, time); | 411 | XSetSelectionOwner (display, selection_atom, selecting_window, time); |
| 412 | x_check_errors (display, "Can't set selection: %s"); | 412 | x_check_errors (display, "Can't set selection: %s"); |
| 413 | x_uncatch_errors (display); | 413 | x_uncatch_errors (); |
| 414 | UNBLOCK_INPUT; | 414 | UNBLOCK_INPUT; |
| 415 | 415 | ||
| 416 | /* Now update the local cache */ | 416 | /* Now update the local cache */ |
| @@ -586,7 +586,7 @@ x_decline_selection_request (event) | |||
| 586 | x_catch_errors (reply.display); | 586 | x_catch_errors (reply.display); |
| 587 | XSendEvent (reply.display, reply.requestor, False, 0L, (XEvent *) &reply); | 587 | XSendEvent (reply.display, reply.requestor, False, 0L, (XEvent *) &reply); |
| 588 | XFlush (reply.display); | 588 | XFlush (reply.display); |
| 589 | x_uncatch_errors (reply.display); | 589 | x_uncatch_errors (); |
| 590 | UNBLOCK_INPUT; | 590 | UNBLOCK_INPUT; |
| 591 | } | 591 | } |
| 592 | 592 | ||
| @@ -860,7 +860,7 @@ x_reply_selection_request (event, format, data, size, type) | |||
| 860 | BLOCK_INPUT; | 860 | BLOCK_INPUT; |
| 861 | 861 | ||
| 862 | unbind_to (count, Qnil); | 862 | unbind_to (count, Qnil); |
| 863 | x_uncatch_errors (display); | 863 | x_uncatch_errors (); |
| 864 | UNBLOCK_INPUT; | 864 | UNBLOCK_INPUT; |
| 865 | } | 865 | } |
| 866 | 866 | ||
| @@ -1434,7 +1434,7 @@ x_get_foreign_selection (selection_symbol, target_type, time_stamp) | |||
| 1434 | BLOCK_INPUT; | 1434 | BLOCK_INPUT; |
| 1435 | unbind_to (count, Qnil); | 1435 | unbind_to (count, Qnil); |
| 1436 | x_check_errors (display, "Cannot get selection: %s"); | 1436 | x_check_errors (display, "Cannot get selection: %s"); |
| 1437 | x_uncatch_errors (display); | 1437 | x_uncatch_errors (); |
| 1438 | UNBLOCK_INPUT; | 1438 | UNBLOCK_INPUT; |
| 1439 | 1439 | ||
| 1440 | if (NILP (XCAR (reading_selection_reply))) | 1440 | if (NILP (XCAR (reading_selection_reply))) |
| @@ -2673,7 +2673,7 @@ If the value is 0 or the atom is not known, return the empty string. */) | |||
| 2673 | if (! x_had_errors_p (dpy)) | 2673 | if (! x_had_errors_p (dpy)) |
| 2674 | ret = make_string (name, strlen (name)); | 2674 | ret = make_string (name, strlen (name)); |
| 2675 | 2675 | ||
| 2676 | x_uncatch_errors (dpy); | 2676 | x_uncatch_errors (); |
| 2677 | 2677 | ||
| 2678 | if (atom && name) XFree (name); | 2678 | if (atom && name) XFree (name); |
| 2679 | if (NILP (ret)) ret = make_string ("", 0); | 2679 | if (NILP (ret)) ret = make_string ("", 0); |
| @@ -2849,7 +2849,7 @@ are ignored. */) | |||
| 2849 | XSendEvent (dpyinfo->display, wdest, propagate, mask, &event); | 2849 | XSendEvent (dpyinfo->display, wdest, propagate, mask, &event); |
| 2850 | XFlush (dpyinfo->display); | 2850 | XFlush (dpyinfo->display); |
| 2851 | } | 2851 | } |
| 2852 | x_uncatch_errors (dpyinfo->display); | 2852 | x_uncatch_errors (); |
| 2853 | UNBLOCK_INPUT; | 2853 | UNBLOCK_INPUT; |
| 2854 | 2854 | ||
| 2855 | return Qnil; | 2855 | return Qnil; |
diff --git a/src/xterm.c b/src/xterm.c index b7c1ba14caf..7b952e1f45f 100644 --- a/src/xterm.c +++ b/src/xterm.c | |||
| @@ -325,7 +325,7 @@ void x_delete_display P_ ((struct x_display_info *)); | |||
| 325 | 325 | ||
| 326 | static int x_io_error_quitter P_ ((Display *)); | 326 | static int x_io_error_quitter P_ ((Display *)); |
| 327 | void x_catch_errors P_ ((Display *)); | 327 | void x_catch_errors P_ ((Display *)); |
| 328 | void x_uncatch_errors P_ ((Display *)); | 328 | void x_uncatch_errors P_ ((void)); |
| 329 | void x_lower_frame P_ ((struct frame *)); | 329 | void x_lower_frame P_ ((struct frame *)); |
| 330 | void x_scroll_bar_clear P_ ((struct frame *)); | 330 | void x_scroll_bar_clear P_ ((struct frame *)); |
| 331 | int x_had_errors_p P_ ((Display *)); | 331 | int x_had_errors_p P_ ((Display *)); |
| @@ -3795,7 +3795,7 @@ XTmouse_position (fp, insist, bar_window, part, x, y, time) | |||
| 3795 | if (x_had_errors_p (FRAME_X_DISPLAY (*fp))) | 3795 | if (x_had_errors_p (FRAME_X_DISPLAY (*fp))) |
| 3796 | f1 = 0; | 3796 | f1 = 0; |
| 3797 | 3797 | ||
| 3798 | x_uncatch_errors (FRAME_X_DISPLAY (*fp)); | 3798 | x_uncatch_errors (); |
| 3799 | 3799 | ||
| 3800 | /* If not, is it one of our scroll bars? */ | 3800 | /* If not, is it one of our scroll bars? */ |
| 3801 | if (! f1) | 3801 | if (! f1) |
| @@ -5721,7 +5721,7 @@ handle_one_xevent (dpyinfo, eventp, finish, hold_quit) | |||
| 5721 | /* This is needed to detect the error | 5721 | /* This is needed to detect the error |
| 5722 | if there is an error. */ | 5722 | if there is an error. */ |
| 5723 | XSync (d, False); | 5723 | XSync (d, False); |
| 5724 | x_uncatch_errors (d); | 5724 | x_uncatch_errors (); |
| 5725 | } | 5725 | } |
| 5726 | /* Not certain about handling scroll bars here */ | 5726 | /* Not certain about handling scroll bars here */ |
| 5727 | #endif /* 0 */ | 5727 | #endif /* 0 */ |
| @@ -7529,19 +7529,16 @@ x_catch_errors (dpy) | |||
| 7529 | DPY should be the display that was passed to x_catch_errors. */ | 7529 | DPY should be the display that was passed to x_catch_errors. */ |
| 7530 | 7530 | ||
| 7531 | void | 7531 | void |
| 7532 | x_uncatch_errors (dpy) | 7532 | x_uncatch_errors () |
| 7533 | Display *dpy; | ||
| 7534 | { | 7533 | { |
| 7535 | struct x_error_message_stack *tmp; | 7534 | struct x_error_message_stack *tmp; |
| 7536 | 7535 | ||
| 7537 | eassert (x_error_message && dpy == x_error_message->dpy); | ||
| 7538 | |||
| 7539 | /* The display may have been closed before this function is called. | 7536 | /* The display may have been closed before this function is called. |
| 7540 | Check if it is still open before calling XSync. */ | 7537 | Check if it is still open before calling XSync. */ |
| 7541 | if (x_display_info_for_display (dpy) != 0) | 7538 | if (x_display_info_for_display (x_error_message->dpy) != 0) |
| 7542 | { | 7539 | { |
| 7543 | BLOCK_INPUT; | 7540 | BLOCK_INPUT; |
| 7544 | XSync (dpy, False); | 7541 | XSync (x_error_message->dpy, False); |
| 7545 | UNBLOCK_INPUT; | 7542 | UNBLOCK_INPUT; |
| 7546 | } | 7543 | } |
| 7547 | 7544 | ||
| @@ -7566,7 +7563,7 @@ x_check_errors (dpy, format) | |||
| 7566 | { | 7563 | { |
| 7567 | char string[X_ERROR_MESSAGE_SIZE]; | 7564 | char string[X_ERROR_MESSAGE_SIZE]; |
| 7568 | bcopy (x_error_message->string, string, X_ERROR_MESSAGE_SIZE); | 7565 | bcopy (x_error_message->string, string, X_ERROR_MESSAGE_SIZE); |
| 7569 | x_uncatch_errors (dpy); | 7566 | x_uncatch_errors (); |
| 7570 | error (format, string); | 7567 | error (format, string); |
| 7571 | } | 7568 | } |
| 7572 | } | 7569 | } |
| @@ -7726,7 +7723,7 @@ x_connection_closed (dpy, error_message) | |||
| 7726 | if (dpyinfo) | 7723 | if (dpyinfo) |
| 7727 | x_delete_display (dpyinfo); | 7724 | x_delete_display (dpyinfo); |
| 7728 | 7725 | ||
| 7729 | x_uncatch_errors (dpy); | 7726 | x_uncatch_errors (); |
| 7730 | 7727 | ||
| 7731 | if (x_display_list == 0) | 7728 | if (x_display_list == 0) |
| 7732 | { | 7729 | { |
| @@ -9452,7 +9449,7 @@ x_list_fonts (f, pattern, size, maxnames) | |||
| 9452 | } | 9449 | } |
| 9453 | } | 9450 | } |
| 9454 | 9451 | ||
| 9455 | x_uncatch_errors (dpy); | 9452 | x_uncatch_errors (); |
| 9456 | UNBLOCK_INPUT; | 9453 | UNBLOCK_INPUT; |
| 9457 | 9454 | ||
| 9458 | if (names) | 9455 | if (names) |
| @@ -9553,7 +9550,7 @@ x_list_fonts (f, pattern, size, maxnames) | |||
| 9553 | thisinfo = NULL; | 9550 | thisinfo = NULL; |
| 9554 | x_clear_errors (dpy); | 9551 | x_clear_errors (dpy); |
| 9555 | } | 9552 | } |
| 9556 | x_uncatch_errors (dpy); | 9553 | x_uncatch_errors (); |
| 9557 | UNBLOCK_INPUT; | 9554 | UNBLOCK_INPUT; |
| 9558 | 9555 | ||
| 9559 | if (thisinfo) | 9556 | if (thisinfo) |
| @@ -9756,7 +9753,7 @@ x_load_font (f, fontname, size) | |||
| 9756 | font = NULL; | 9753 | font = NULL; |
| 9757 | x_clear_errors (FRAME_X_DISPLAY (f)); | 9754 | x_clear_errors (FRAME_X_DISPLAY (f)); |
| 9758 | } | 9755 | } |
| 9759 | x_uncatch_errors (FRAME_X_DISPLAY (f)); | 9756 | x_uncatch_errors (); |
| 9760 | UNBLOCK_INPUT; | 9757 | UNBLOCK_INPUT; |
| 9761 | if (!font) | 9758 | if (!font) |
| 9762 | return NULL; | 9759 | return NULL; |
| @@ -10541,7 +10538,7 @@ x_term_init (display_name, xrm_option, resource_name) | |||
| 10541 | abort (); | 10538 | abort (); |
| 10542 | if (x_had_errors_p (dpy) || !XQueryFont (dpy, font)) | 10539 | if (x_had_errors_p (dpy) || !XQueryFont (dpy, font)) |
| 10543 | XrmPutLineResource (&xrdb, "Emacs.dialog.*.font: 9x15"); | 10540 | XrmPutLineResource (&xrdb, "Emacs.dialog.*.font: 9x15"); |
| 10544 | x_uncatch_errors (dpy); | 10541 | x_uncatch_errors (); |
| 10545 | } | 10542 | } |
| 10546 | #endif | 10543 | #endif |
| 10547 | #endif | 10544 | #endif |
diff --git a/src/xterm.h b/src/xterm.h index b2fa92fa4e4..a84a42d85d3 100644 --- a/src/xterm.h +++ b/src/xterm.h | |||
| @@ -960,7 +960,7 @@ void x_iconify_frame P_ ((struct frame *)); | |||
| 960 | void x_wm_set_size_hint P_ ((struct frame *, long, int)); | 960 | void x_wm_set_size_hint P_ ((struct frame *, long, int)); |
| 961 | void x_catch_errors P_ ((Display *)); | 961 | void x_catch_errors P_ ((Display *)); |
| 962 | int x_had_errors_p P_ ((Display *)); | 962 | int x_had_errors_p P_ ((Display *)); |
| 963 | void x_uncatch_errors P_ ((Display *)); | 963 | void x_uncatch_errors P_ ((void)); |
| 964 | void x_check_errors P_ ((Display *, char *)); | 964 | void x_check_errors P_ ((Display *, char *)); |
| 965 | int x_text_icon P_ ((struct frame *, char *)); | 965 | int x_text_icon P_ ((struct frame *, char *)); |
| 966 | int x_bitmap_icon P_ ((struct frame *, Lisp_Object)); | 966 | int x_bitmap_icon P_ ((struct frame *, Lisp_Object)); |
| @@ -977,7 +977,7 @@ extern int x_bitmap_icon P_ ((struct frame *, Lisp_Object)); | |||
| 977 | extern void x_catch_errors P_ ((Display *)); | 977 | extern void x_catch_errors P_ ((Display *)); |
| 978 | extern void x_check_errors P_ ((Display *, char *)); | 978 | extern void x_check_errors P_ ((Display *, char *)); |
| 979 | extern int x_had_errors_p P_ ((Display *)); | 979 | extern int x_had_errors_p P_ ((Display *)); |
| 980 | extern void x_uncatch_errors P_ ((Display *)); | 980 | extern void x_uncatch_errors P_ ((void)); |
| 981 | extern void x_set_window_size P_ ((struct frame *, int, int, int)); | 981 | extern void x_set_window_size P_ ((struct frame *, int, int, int)); |
| 982 | extern void x_set_mouse_position P_ ((struct frame *, int, int)); | 982 | extern void x_set_mouse_position P_ ((struct frame *, int, int)); |
| 983 | extern void x_set_mouse_pixel_position P_ ((struct frame *, int, int)); | 983 | extern void x_set_mouse_pixel_position P_ ((struct frame *, int, int)); |