From: Roland McGrath Date: Mon, 2 Aug 1993 22:16:09 +0000 (+0000) Subject: (Fprevious_frame): New function, for parity with Fnext_frame. X-Git-Tag: emacs-19.34~11427 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=ef2c57aca04c8311f3e7bb872bdae769bba9a30b;p=emacs.git (Fprevious_frame): New function, for parity with Fnext_frame. (syms_of_frame): Add defsubr for Sprevious_frame. --- diff --git a/src/frame.c b/src/frame.c index 553ee9e0bb5..8f6860d24fe 100644 --- a/src/frame.c +++ b/src/frame.c @@ -570,6 +570,7 @@ prev_frame (frame, minibuf) return prev; } + DEFUN ("next-frame", Fnext_frame, Snext_frame, 0, 2, 0, "Return the next frame in the frame list after FRAME.\n\ By default, skip minibuffer-only frames.\n\ @@ -591,6 +592,27 @@ If MINIFRAME is non-nil and not a window, include all frames.") return next_frame (frame, miniframe); } +DEFUN ("previous-frame", Fprevious_frame, Sprevious_frame, 0, 2, 0, + "Return the previous frame in the frame list before FRAME.\n\ +By default, skip minibuffer-only frames.\n\ +If omitted, FRAME defaults to the selected frame.\n\ +If optional argument MINIFRAME is nil, exclude minibuffer-only frames.\n\ +If MINIFRAME is a window, include only frames using that window for their\n\ +minibuffer.\n\ +If MINIFRAME is non-nil and not a window, include all frames.") + (frame, miniframe) + Lisp_Object frame, miniframe; +{ + Lisp_Object tail; + + if (NILP (frame)) + XSET (frame, Lisp_Frame, selected_frame); + else + CHECK_LIVE_FRAME (frame, 0); + + return prev_frame (frame, miniframe); +} + DEFUN ("delete-frame", Fdelete_frame, Sdelete_frame, 0, 2, "", "Delete FRAME, permanently eliminating it from use.\n\ @@ -1490,6 +1512,7 @@ For values specific to the separate minibuffer frame, see\n\ defsubr (&Sframe_selected_window); defsubr (&Sframe_list); defsubr (&Snext_frame); + defsubr (&Sprevious_frame); defsubr (&Sdelete_frame); defsubr (&Smouse_position); defsubr (&Sset_mouse_position);