]> code.delx.au - gnu-emacs-elpa/commitdiff
avy.el (avy-push-mark): Bring back push-mark
authorOleh Krehel <ohwoeowho@gmail.com>
Fri, 21 Aug 2015 18:46:03 +0000 (20:46 +0200)
committerOleh Krehel <ohwoeowho@gmail.com>
Fri, 21 Aug 2015 18:59:19 +0000 (20:59 +0200)
Fixes abo-abo/ace-window#41

avy.el

diff --git a/avy.el b/avy.el
index 44cecbcd6899d2ea6cdd9660270eecce12a7cdd3..ea0cb8d26650f1c944acbace4322dd997a50075c 100644 (file)
--- a/avy.el
+++ b/avy.el
@@ -1053,7 +1053,9 @@ The window scope is determined by `avy-all-windows' (ARG negates it)."
 (defun avy-push-mark ()
   "Store the current point and window."
   (ring-insert avy-ring
-               (cons (point) (selected-window))))
+               (cons (point) (selected-window)))
+  (unless (region-active-p)
+    (push-mark)))
 
 (defun avy-pop-mark ()
   "Jump back to the last location of `avy-push-mark'."