diff options
author | Gerd Moellmann <gerd@gnu.org> | 1999-11-01 12:15:41 +0000 |
---|---|---|
committer | Gerd Moellmann <gerd@gnu.org> | 1999-11-01 12:15:41 +0000 |
commit | aeb721fe9ca9239ad9ca0fe6b2fe4f57f97da9c2 (patch) | |
tree | 7575da00bf4b5de030e816f6b3b90f07ae999947 /lisp | |
parent | 314808dc648814f3b68fe45db3f14ca414db63bd (diff) | |
download | emacs-aeb721fe9ca9239ad9ca0fe6b2fe4f57f97da9c2.tar.gz |
(walk-windows): If ALL-FRAMES is a frame,
start on that frame. Use save-selected-window.
Diffstat (limited to 'lisp')
-rw-r--r-- | lisp/ChangeLog | 5 | ||||
-rw-r--r-- | lisp/window.el | 18 |
2 files changed, 16 insertions, 7 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 9721ec5d0f3..2ede4abe932 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,8 @@ +1999-11-01 Richard M. Stallman <rms@caffeine.ai.mit.edu> + + * window.el (walk-windows): If ALL-FRAMES is a frame, + start on that frame. Use save-selected-window. + 1999-11-01 Gerd Moellmann <gerd@gnu.org> * simple.el (end-of-buffer): Use window-end to find the window end diff --git a/lisp/window.el b/lisp/window.el index c26b79af485..e5639a50827 100644 --- a/lisp/window.el +++ b/lisp/window.el @@ -62,17 +62,21 @@ ALL-FRAMES nil or omitted means cycle within the frames as specified above. ALL-FRAMES = `visible' means include windows on all visible frames. ALL-FRAMES = 0 means include windows on all visible and iconified frames. ALL-FRAMES = t means include windows on all frames including invisible frames. +If ALL-FRAMES is a frame, it means include windows on that frame. Anything else means restrict to the selected frame." ;; If we start from the minibuffer window, don't fail to come back to it. (if (window-minibuffer-p (selected-window)) (setq minibuf t)) - (let* ((walk-windows-start (selected-window)) - (walk-windows-current walk-windows-start)) - (while (progn - (setq walk-windows-current - (next-window walk-windows-current minibuf all-frames)) - (funcall proc walk-windows-current) - (not (eq walk-windows-current walk-windows-start)))))) + (save-selected-window + (if (framep all-frames) + (select-window (frame-first-window all-frames))) + (let* ((walk-windows-start (selected-window)) + (walk-windows-current walk-windows-start)) + (while (progn + (setq walk-windows-current + (next-window walk-windows-current minibuf all-frames)) + (funcall proc walk-windows-current) + (not (eq walk-windows-current walk-windows-start))))))) (defun minibuffer-window-active-p (window) "Return t if WINDOW (a minibuffer window) is now active." |