1
0
mirror of https://git.savannah.gnu.org/git/emacs.git synced 2024-12-23 10:34:07 +00:00

(mouse-set-secondary): Update mouse-secondary-overlay.

This commit is contained in:
Chong Yidong 2007-04-01 17:45:20 +00:00
parent b831b4b8b8
commit 3e4f866be3

View File

@ -1521,7 +1521,11 @@ This must be bound to a mouse drag event."
(with-current-buffer (window-buffer (posn-window posn))
(if (numberp (posn-point posn))
(setq beg (posn-point posn)))
(move-overlay mouse-secondary-overlay beg (posn-point end)))))
(move-overlay mouse-secondary-overlay beg (posn-point end))
(x-set-selection
'SECONDARY
(buffer-substring (overlay-start mouse-secondary-overlay)
(overlay-end mouse-secondary-overlay))))))
(defun mouse-drag-secondary (start-event)
"Set the secondary selection to the text that the mouse is dragged over.