]> git.eshelyaron.com Git - emacs.git/commitdiff
(mouse-kill): Select the clicked window first.
authorKarl Heuer <kwzh@gnu.org>
Fri, 11 Mar 1994 04:13:50 +0000 (04:13 +0000)
committerKarl Heuer <kwzh@gnu.org>
Fri, 11 Mar 1994 04:13:50 +0000 (04:13 +0000)
lisp/mouse.el

index d40fea1f50f103a981b15a5b6010422d3c0f0db3..1fd789a546c272cb80b58e57c62d053b2b589f87 100644 (file)
@@ -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)))))