(mouse-kill): Select the clicked window first.
This commit is contained in:
parent
25bef3dd72
commit
142c76727e
1 changed files with 3 additions and 1 deletions
|
@ -380,7 +380,9 @@ This must be bound to a mouse click."
|
|||
The text is saved in the kill ring, as with \\[kill-region]."
|
||||
(interactive "e")
|
||||
(mouse-minibuffer-check click)
|
||||
(let ((click-posn (posn-point (event-start click))))
|
||||
(let* ((posn (event-start click))
|
||||
(click-posn (posn-point posn)))
|
||||
(select-window (posn-window posn))
|
||||
(if (numberp click-posn)
|
||||
(kill-region (min (point) click-posn)
|
||||
(max (point) click-posn)))))
|
||||
|
|
Loading…
Add table
Reference in a new issue