aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorStefan Monnier2019-03-08 17:20:58 -0500
committerStefan Monnier2019-03-08 17:20:58 -0500
commit76fdae8549ab54bd075520134deec0d69ac6987d (patch)
treeee6076c1669b506aa2207c7d2af935f2173a5144
parentbec7fb2988c98a4103cc77bebc454c81a89e0f49 (diff)
downloademacs-76fdae8549ab54bd075520134deec0d69ac6987d.tar.gz
emacs-76fdae8549ab54bd075520134deec0d69ac6987d.zip
* lisp/emacs-lisp/cursor-sensor.el: Fix sensor behavior with overlays
(cursor-sensor--detect): Also consult overlay properties when checking to see if we just moved inside the same "element" as opposed to changing from one to another of the same type.
-rw-r--r--lisp/emacs-lisp/cursor-sensor.el4
1 files changed, 2 insertions, 2 deletions
diff --git a/lisp/emacs-lisp/cursor-sensor.el b/lisp/emacs-lisp/cursor-sensor.el
index a21d78998ac..66b940f7fb3 100644
--- a/lisp/emacs-lisp/cursor-sensor.el
+++ b/lisp/emacs-lisp/cursor-sensor.el
@@ -160,7 +160,7 @@ By convention, this is a list of symbols where each symbol stands for the
160 (setcdr old nil)) 160 (setcdr old nil))
161 (if (or (and (null new) (null (cdr old))) 161 (if (or (and (null new) (null (cdr old)))
162 (and (eq new (cdr old)) 162 (and (eq new (cdr old))
163 (eq (next-single-property-change 163 (eq (next-single-char-property-change
164 start 'cursor-sensor-functions nil end) 164 start 'cursor-sensor-functions nil end)
165 end))) 165 end)))
166 ;; Clearly nothing to do. 166 ;; Clearly nothing to do.
@@ -172,7 +172,7 @@ By convention, this is a list of symbols where each symbol stands for the
172 (let ((pos start) 172 (let ((pos start)
173 (missing nil)) 173 (missing nil))
174 (while (< pos end) 174 (while (< pos end)
175 (setq pos (next-single-property-change 175 (setq pos (next-single-char-property-change
176 pos 'cursor-sensor-functions 176 pos 'cursor-sensor-functions
177 nil end)) 177 nil end))
178 (unless (memq f (get-char-property 178 (unless (memq f (get-char-property