hydra.el (hydra-disable): Call the exit action only in one frame

* hydra.el (hydra-disable): Move the action calling code out
  of (frame-list) loop.

The (frame-list) loop was added to fix #105 to restor the
terminal-local-map in all frames. There's no reason for action-calling
code to be in that loop.

Fixes #169.
master
Oleh Krehel 11 years ago
parent 2403973be4
commit 90a4e76c37
  1. 12
      hydra.el

@ -149,12 +149,12 @@ warn: keep KEYMAP and issue a warning instead of running the command."
(dolist (frame (frame-list))
(with-selected-frame frame
(when overriding-terminal-local-map
(internal-pop-keymap hydra-curr-map 'overriding-terminal-local-map)
(unless hydra--ignore
(when hydra-curr-on-exit
(let ((on-exit hydra-curr-on-exit))
(setq hydra-curr-on-exit nil)
(funcall on-exit))))))))
(internal-pop-keymap hydra-curr-map 'overriding-terminal-local-map))))
(unless hydra--ignore
(when hydra-curr-on-exit
(let ((on-exit hydra-curr-on-exit))
(setq hydra-curr-on-exit nil)
(funcall on-exit)))))
(unless (fboundp 'internal-push-keymap)
(defun internal-push-keymap (keymap symbol)

Loading…
Cancel
Save