ace-window.el (aw-switch-to-window): Push early

* ace-window.el (aw-switch-to-window): Push current window to ring
  before switching frames. It's OK to push without checking, the check
  is performed in `aw--push-window'.

Fixes #61
old-master
Oleh Krehel 11 years ago
parent f786679f89
commit 4a89cccedb
  1. 5
      ace-window.el

@ -423,13 +423,12 @@ Windows are numbered top down, left to right."
(defun aw-switch-to-window (window)
"Switch to the window WINDOW."
(let ((frame (window-frame window)))
(aw--push-window (selected-window))
(when (and (frame-live-p frame)
(not (eq frame (selected-frame))))
(select-frame-set-input-focus frame))
(if (window-live-p window)
(progn
(aw--push-window (selected-window))
(select-window window))
(select-window window)
(error "Got a dead window %S" window))))
(defun aw-flip-window ()

Loading…
Cancel
Save