From 3b97e035c014d4626fde54b675f5a39f84f942eb Mon Sep 17 00:00:00 2001 From: Sami Samhuri Date: Fri, 14 May 2010 00:05:28 -0700 Subject: [PATCH] fixed up other-window-in-any-frame --- emacs | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/emacs b/emacs index 20b87ea..8262079 100644 --- a/emacs +++ b/emacs @@ -372,14 +372,14 @@ switch to that frame first using `select-frame-set-input-focus'. If N is non-nil switch to the nth next window." (interactive "p") - (let ((window (next-window (selected-window) nil 'visible))) - (when (not (member window (window-list))) - (dolist (frame (delq (selected-frame) (frame-list))) - (when (member window (window-list frame)) - (select-frame-set-input-focus frame)))) - (select-window window)) - (unless (= 1 arg) - (other-window-in-any-frame (- arg 1)))) + (while (> arg 0) + (let ((window (next-window (selected-window) nil 'visible))) + (when (not (member window (window-list))) + (dolist (frame (delq (selected-frame) (frame-list))) + (when (member window (window-list frame)) + (select-frame-set-input-focus frame)))) + (select-window window)) + (decf arg))) ;; Reload the .emacs file with a minimum of effort, ;; first saving histories with Persistent