aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorGerd Moellmann2000-10-26 12:07:17 +0000
committerGerd Moellmann2000-10-26 12:07:17 +0000
commit0e6623421d7f95a691cc66726e9ff38fb5bc830e (patch)
tree6885b4515b3816fe7c66b5c11b065d1dc2898235 /src
parent6c5b90af8664ac6b44c3e5ed1210ac175e0b8daf (diff)
downloademacs-0e6623421d7f95a691cc66726e9ff38fb5bc830e.tar.gz
emacs-0e6623421d7f95a691cc66726e9ff38fb5bc830e.zip
(Fdelete_frame): Doc fix. Move running the hook
down after the last error condition check.
Diffstat (limited to 'src')
-rw-r--r--src/frame.c22
1 files changed, 13 insertions, 9 deletions
diff --git a/src/frame.c b/src/frame.c
index 0233b171e24..d495846fcdf 100644
--- a/src/frame.c
+++ b/src/frame.c
@@ -1137,7 +1137,10 @@ DEFUN ("delete-frame", Fdelete_frame, Sdelete_frame, 0, 2, "",
1137If omitted, FRAME defaults to the selected frame.\n\ 1137If omitted, FRAME defaults to the selected frame.\n\
1138A frame may not be deleted if its minibuffer is used by other frames.\n\ 1138A frame may not be deleted if its minibuffer is used by other frames.\n\
1139Normally, you may not delete a frame if all other frames are invisible,\n\ 1139Normally, you may not delete a frame if all other frames are invisible,\n\
1140but if the second optional argument FORCE is non-nil, you may do so.") 1140but if the second optional argument FORCE is non-nil, you may do so.\n\
1141\n\
1142This function runs `delete-frame-hook' before actually deleting the\n\
1143frame. The hook is called with one argument FRAME.")
1141 (frame, force) 1144 (frame, force)
1142 Lisp_Object frame, force; 1145 Lisp_Object frame, force;
1143{ 1146{
@@ -1169,14 +1172,6 @@ but if the second optional argument FORCE is non-nil, you may do so.")
1169 error ("Attempt to delete the only frame"); 1172 error ("Attempt to delete the only frame");
1170#endif 1173#endif
1171 1174
1172 if (!NILP (Vrun_hooks))
1173 {
1174 Lisp_Object args[2];
1175 args[0] = intern ("delete-frame-hook");
1176 args[1] = frame;
1177 Frun_hook_with_args (2, args);
1178 }
1179
1180 /* Does this frame have a minibuffer, and is it the surrogate 1175 /* Does this frame have a minibuffer, and is it the surrogate
1181 minibuffer for any other frame? */ 1176 minibuffer for any other frame? */
1182 if (FRAME_HAS_MINIBUF_P (XFRAME (frame))) 1177 if (FRAME_HAS_MINIBUF_P (XFRAME (frame)))
@@ -1198,6 +1193,15 @@ but if the second optional argument FORCE is non-nil, you may do so.")
1198 } 1193 }
1199 } 1194 }
1200 1195
1196 /* Run `delete-frame-hook'. */
1197 if (!NILP (Vrun_hooks))
1198 {
1199 Lisp_Object args[2];
1200 args[0] = intern ("delete-frame-hook");
1201 args[1] = frame;
1202 Frun_hook_with_args (2, args);
1203 }
1204
1201 minibuffer_selected = EQ (minibuf_window, selected_window); 1205 minibuffer_selected = EQ (minibuf_window, selected_window);
1202 1206
1203 /* Don't let the frame remain selected. */ 1207 /* Don't let the frame remain selected. */