From 2a0a63ab4a6bab8523e5e37bf7e66b3eeafb0e0d Mon Sep 17 00:00:00 2001 From: Sean Whitton Date: Sat, 5 Nov 2022 12:26:23 -0700 Subject: spw/back-and-forth-noselect: select the window & rename the command I belive this should have been done in 5ae9d445, as part of undoing 9a8a8b2d. --- .emacs.d/init.el | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.emacs.d/init.el b/.emacs.d/init.el index 4bb24694..c195f234 100644 --- a/.emacs.d/init.el +++ b/.emacs.d/init.el @@ -1239,16 +1239,16 @@ don't consider windows satisfying the predicate EXCLUDE." (setq best-time time) (setq best-window window))))) -(defun spw/back-and-forth-noselect (arg) +(defun spw/back-and-forth (arg) (interactive "P") (if arg ;; if there's a prefix arg then just `other-window', so that's still ;; available on M-1 C-x o (call-interactively #'other-window) (if-let ((window (spw/get-mru-window))) - (select-window window 'mark-for-redisplay) + (select-window window) (user-error "No other window to select")))) -(global-set-key [remap other-window] #'spw/back-and-forth-noselect) +(global-set-key [remap other-window] #'spw/back-and-forth) (defun spw/other-window-noselect (count &optional interactive) (interactive "p\np") -- cgit v1.2.3