aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorJim Blandy1993-03-21 06:53:04 +0000
committerJim Blandy1993-03-21 06:53:04 +0000
commit0f85737cab24dda270770577bd2810c266f6d497 (patch)
treee3d41dc92984e33066cb12afe7d887d8fd12948e /src
parentd5b2799ef633ff34a942abb3c7d7ce12c0ccf425 (diff)
downloademacs-0f85737cab24dda270770577bd2810c266f6d497.tar.gz
emacs-0f85737cab24dda270770577bd2810c266f6d497.zip
* frame.c (Fhandle_switch_frame): Renamed from Fselect_frame.
Doc changed in anticipation of new purpose. (Fselect_frame): Just call Fhandle_switch_frame for now.
Diffstat (limited to 'src')
-rw-r--r--src/frame.c35
1 files changed, 23 insertions, 12 deletions
diff --git a/src/frame.c b/src/frame.c
index 2b3e9bb2fd9..8eea8d43ca2 100644
--- a/src/frame.c
+++ b/src/frame.c
@@ -324,17 +324,27 @@ make_terminal_frame ()
324} 324}
325 325
326DEFUN ("select-frame", Fselect_frame, Sselect_frame, 1, 2, "e", 326DEFUN ("select-frame", Fselect_frame, Sselect_frame, 1, 2, "e",
327 "Select the frame FRAME. FRAME's selected window becomes \"the\"\n\ 327 "Select the frame FRAME.\n\
328selected window. If the optional parameter NO-ENTER is non-nil, don't\n\ 328Subseqent editing commands apply to its selected window.\n\
329focus on that frame.\n\ 329The selection of FRAME lasts until the next time the user does\n\
330\n\ 330something to select a different frame, or until the next time this\n\
331This function is interactive, and may be bound to the ``switch-frame''\n\ 331function is called.")
332event; when invoked this way, it switches to the frame named in the\n\ 332 (frame, no_enter)
333event. When called from lisp, FRAME may be a ``switch-frame'' event;\n\ 333 Lisp_Object frame, no_enter;
334if it is, select the frame named in the event.\n\ 334{
335 return Fhandle_switch_frame (frame, no_enter);
336}
337
338
339DEFUN ("handle-switch-frame", Fhandle_switch_frame, Shandle_switch_frame, 1, 2, "e",
340 "Handle a switch-frame event EVENT.\n\
341Switch-frame events is usually bound to this function.\n\
342A switch-frame event tells Emacs that the window manager has requested\n\
343that the user's events be directed to the frame mentioned in the event.\n\
344This function selects the selected window of the frame of EVENT.\n\
335\n\ 345\n\
336Changing the selected frame can change focus redirections. See\n\ 346If EVENT is frame object, handle it as if it were a switch-frame event\n\
337`redirect-frame-focus' for details.") 347to that frame.")
338 (frame, no_enter) 348 (frame, no_enter)
339 Lisp_Object frame, no_enter; 349 Lisp_Object frame, no_enter;
340{ 350{
@@ -641,7 +651,7 @@ A frame may not be deleted if its minibuffer is used by other frames.")
641 651
642 /* Don't let the frame remain selected. */ 652 /* Don't let the frame remain selected. */
643 if (f == selected_frame) 653 if (f == selected_frame)
644 Fselect_frame (next_frame (frame, Qt), Qnil); 654 Fhandle_switch_frame (next_frame (frame, Qt), Qnil);
645 655
646 /* Don't allow minibuf_window to remain on a deleted frame. */ 656 /* Don't allow minibuf_window to remain on a deleted frame. */
647 if (EQ (f->minibuffer_window, minibuf_window)) 657 if (EQ (f->minibuffer_window, minibuf_window))
@@ -1463,6 +1473,7 @@ For values specific to the separate minibuffer frame, see\n\
1463 1473
1464 defsubr (&Sframep); 1474 defsubr (&Sframep);
1465 defsubr (&Sframe_live_p); 1475 defsubr (&Sframe_live_p);
1476 defsubr (&Shandle_switch_frame);
1466 defsubr (&Sselect_frame); 1477 defsubr (&Sselect_frame);
1467 defsubr (&Sselected_frame); 1478 defsubr (&Sselected_frame);
1468 defsubr (&Swindow_frame); 1479 defsubr (&Swindow_frame);
@@ -1503,7 +1514,7 @@ For values specific to the separate minibuffer frame, see\n\
1503 1514
1504keys_of_frame () 1515keys_of_frame ()
1505{ 1516{
1506 initial_define_lispy_key (global_map, "switch-frame", "select-frame"); 1517 initial_define_lispy_key (global_map, "switch-frame", "handle-switch-frame");
1507} 1518}
1508 1519
1509#else /* not MULTI_FRAME */ 1520#else /* not MULTI_FRAME */