mirror of
https://git.savannah.gnu.org/git/emacs.git
synced 2024-12-25 10:47:00 +00:00
(set-mark): When POS is nil, always clear mark-active.
This commit is contained in:
parent
bb1e67a022
commit
24c2285241
@ -1335,8 +1335,12 @@ store it in a Lisp variable. Example:
|
|||||||
(setq mark-active t)
|
(setq mark-active t)
|
||||||
(run-hooks 'activate-mark-hook)
|
(run-hooks 'activate-mark-hook)
|
||||||
(set-marker (mark-marker) pos (current-buffer)))
|
(set-marker (mark-marker) pos (current-buffer)))
|
||||||
(deactivate-mark)
|
;; Normally we never clear mark-active except in Transient Mark mode.
|
||||||
(set-marker (mark-marker) pos (current-buffer))))
|
;; But when we actually clear out the mark value too,
|
||||||
|
;; we must clear mark-active in any mode.
|
||||||
|
(setq mark-active nil)
|
||||||
|
(run-hooks 'deactivate-mark-hook)
|
||||||
|
(set-marker (mark-marker) nil)))
|
||||||
|
|
||||||
(defvar mark-ring nil
|
(defvar mark-ring nil
|
||||||
"The list of saved former marks of the current buffer,
|
"The list of saved former marks of the current buffer,
|
||||||
|
Loading…
Reference in New Issue
Block a user