diff options
| author | Richard M. Stallman | 1995-02-26 04:17:42 +0000 |
|---|---|---|
| committer | Richard M. Stallman | 1995-02-26 04:17:42 +0000 |
| commit | 9dfab550e65080dfbea91da014ff7a78ceea22df (patch) | |
| tree | 8d6bd9db9231a1da90c8c87074872abac8af9cba | |
| parent | 63c1d3f28cba461d98a0e584840e557426022c5a (diff) | |
| download | emacs-9dfab550e65080dfbea91da014ff7a78ceea22df.tar.gz emacs-9dfab550e65080dfbea91da014ff7a78ceea22df.zip | |
(mouse-kill-secondary): Avoid changing this-command.
Don't clear the secondary selection.
| -rw-r--r-- | lisp/mouse.el | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/lisp/mouse.el b/lisp/mouse.el index 9e4c4827aaf..917cdca28a3 100644 --- a/lisp/mouse.el +++ b/lisp/mouse.el | |||
| @@ -886,12 +886,13 @@ is to prevent accidents." | |||
| 886 | (window-buffer (posn-window (event-start click))) | 886 | (window-buffer (posn-window (event-start click))) |
| 887 | (current-buffer))) | 887 | (current-buffer))) |
| 888 | (error "Select or click on the buffer where the secondary selection is"))) | 888 | (error "Select or click on the buffer where the secondary selection is"))) |
| 889 | (save-excursion | 889 | (let (this-command) |
| 890 | (set-buffer (overlay-buffer mouse-secondary-overlay)) | 890 | (save-excursion |
| 891 | (kill-region (overlay-start mouse-secondary-overlay) | 891 | (set-buffer (overlay-buffer mouse-secondary-overlay)) |
| 892 | (overlay-end mouse-secondary-overlay))) | 892 | (kill-region (overlay-start mouse-secondary-overlay) |
| 893 | (overlay-end mouse-secondary-overlay)))) | ||
| 893 | (delete-overlay mouse-secondary-overlay) | 894 | (delete-overlay mouse-secondary-overlay) |
| 894 | (x-set-selection 'SECONDARY nil) | 895 | ;;; (x-set-selection 'SECONDARY nil) |
| 895 | (setq mouse-secondary-overlay nil)) | 896 | (setq mouse-secondary-overlay nil)) |
| 896 | 897 | ||
| 897 | (defun mouse-secondary-save-then-kill (click) | 898 | (defun mouse-secondary-save-then-kill (click) |