diff options
Diffstat (limited to 'lisp/mouse-sel.el')
-rw-r--r-- | lisp/mouse-sel.el | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/lisp/mouse-sel.el b/lisp/mouse-sel.el index 881329d7167..98f704d005d 100644 --- a/lisp/mouse-sel.el +++ b/lisp/mouse-sel.el @@ -264,8 +264,9 @@ See documentation for mouse-select for more details. This should be bound to a down-mouse event." (interactive "e") (if EVENT (select-window (posn-window (event-end EVENT)))) - (let* ((min (if (and EVENT mark-active) (region-beginning) (point))) - (max (if (and EVENT mark-active) (region-end) (point))) + (let* ((use-region (and (or EVENT transient-mark-mode) mark-active)) + (min (if use-region (region-beginning) (point))) + (max (if use-region (region-end) (point))) (orig-window (selected-window)) (orig-window-frame (window-frame orig-window)) (top (nth 1 (window-edges orig-window))) |