comparison src/xterm.c @ 91732:c33ec1f680a9

* frame.c (Qnoelisp): New symbol. (syms_of_frame): Initialize it. (Fdelete_frame): Use it to distinguish a mere `force' passed from someharmles Elisp code, from a strong `force' from x_connection_closed. * frame.h (Qnoelisp): Declare. * xterm.c (x_connection_closed): Pass `noelisp'.
author Stefan Monnier <monnier@iro.umontreal.ca>
date Sun, 10 Feb 2008 21:56:38 +0000
parents b7a5a89054dc
children c9a3274c0d40
comparison
equal deleted inserted replaced
91731:7efbdc83b944 91732:c33ec1f680a9
8060 = WINDOW_FRAME (XWINDOW (FRAME_MINIBUF_WINDOW (XFRAME (frame)))); 8060 = WINDOW_FRAME (XWINDOW (FRAME_MINIBUF_WINDOW (XFRAME (frame))));
8061 if (FRAME_X_P (XFRAME (frame)) 8061 if (FRAME_X_P (XFRAME (frame))
8062 && FRAME_X_P (XFRAME (minibuf_frame)) 8062 && FRAME_X_P (XFRAME (minibuf_frame))
8063 && ! EQ (frame, minibuf_frame) 8063 && ! EQ (frame, minibuf_frame)
8064 && FRAME_X_DISPLAY_INFO (XFRAME (minibuf_frame)) == dpyinfo) 8064 && FRAME_X_DISPLAY_INFO (XFRAME (minibuf_frame)) == dpyinfo)
8065 Fdelete_frame (frame, Qt); 8065 Fdelete_frame (frame, Qnoelisp);
8066 } 8066 }
8067 8067
8068 /* Now delete all remaining frames on the dead display. 8068 /* Now delete all remaining frames on the dead display.
8069 We are now sure none of these is used as the mini-buffer 8069 We are now sure none of these is used as the mini-buffer
8070 for another frame that we need to delete. */ 8070 for another frame that we need to delete. */
8073 && FRAME_X_DISPLAY_INFO (XFRAME (frame)) == dpyinfo) 8073 && FRAME_X_DISPLAY_INFO (XFRAME (frame)) == dpyinfo)
8074 { 8074 {
8075 /* Set this to t so that Fdelete_frame won't get confused 8075 /* Set this to t so that Fdelete_frame won't get confused
8076 trying to find a replacement. */ 8076 trying to find a replacement. */
8077 FRAME_KBOARD (XFRAME (frame))->Vdefault_minibuffer_frame = Qt; 8077 FRAME_KBOARD (XFRAME (frame))->Vdefault_minibuffer_frame = Qt;
8078 Fdelete_frame (frame, Qt); 8078 Fdelete_frame (frame, Qnoelisp);
8079 } 8079 }
8080 8080
8081 /* We have to close the display to inform Xt that it doesn't 8081 /* We have to close the display to inform Xt that it doesn't
8082 exist anymore. If we don't, Xt will continue to wait for 8082 exist anymore. If we don't, Xt will continue to wait for
8083 events from the display. As a consequence, a sequence of 8083 events from the display. As a consequence, a sequence of
8085 M-x make-frame-on-display RET :1 RET 8085 M-x make-frame-on-display RET :1 RET
8086 ...kill the new frame, so that we get an IO error... 8086 ...kill the new frame, so that we get an IO error...
8087 M-x make-frame-on-display RET :1 RET 8087 M-x make-frame-on-display RET :1 RET
8088 8088
8089 will indefinitely wait in Xt for events for display `:1', opened 8089 will indefinitely wait in Xt for events for display `:1', opened
8090 in the first class to make-frame-on-display. 8090 in the first call to make-frame-on-display.
8091 8091
8092 Closing the display is reported to lead to a bus error on 8092 Closing the display is reported to lead to a bus error on
8093 OpenWindows in certain situations. I suspect that is a bug 8093 OpenWindows in certain situations. I suspect that is a bug
8094 in OpenWindows. I don't know how to circumvent it here. */ 8094 in OpenWindows. I don't know how to circumvent it here. */
8095 8095