aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSam Steingold2010-07-26 15:05:47 -0400
committerSam Steingold2010-07-26 15:05:47 -0400
commitaa2d4bd3438df0855c168c960e03d1f8ea25ae71 (patch)
treea0c7ecef8918cda76642c2a1ae0952b8a38981d6
parent977105dcbf011d1ee119aae22a9b0ae85646a686 (diff)
downloademacs-aa2d4bd3438df0855c168c960e03d1f8ea25ae71.tar.gz
emacs-aa2d4bd3438df0855c168c960e03d1f8ea25ae71.zip
* lisp/mouse.el (mouse-yank-primary, mouse-yank-secondary):
Do not call `x-get-selection' the second time, reuse the value.
-rw-r--r--lisp/ChangeLog5
-rw-r--r--lisp/mouse.el4
2 files changed, 7 insertions, 2 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog
index 9d6f0ed0d98..ff65a6398a8 100644
--- a/lisp/ChangeLog
+++ b/lisp/ChangeLog
@@ -1,3 +1,8 @@
12010-07-26 Sam Steingold <sds@gnu.org>
2
3 * mouse.el (mouse-yank-primary, mouse-yank-secondary):
4 Do not call `x-get-selection' the second time, reuse the value.
5
12010-07-26 Daiki Ueno <ueno@unixuser.org> 62010-07-26 Daiki Ueno <ueno@unixuser.org>
2 7
3 * epa-mail.el (epa-mail-mode-map): Add alternative key bindings 8 * epa-mail.el (epa-mail-mode-map): Add alternative key bindings
diff --git a/lisp/mouse.el b/lisp/mouse.el
index 87cca4044b8..7ba7b031e1e 100644
--- a/lisp/mouse.el
+++ b/lisp/mouse.el
@@ -1282,7 +1282,7 @@ regardless of where you click."
1282 (or mouse-yank-at-point (mouse-set-point click)) 1282 (or mouse-yank-at-point (mouse-set-point click))
1283 (let ((primary (x-get-selection 'PRIMARY))) 1283 (let ((primary (x-get-selection 'PRIMARY)))
1284 (if primary 1284 (if primary
1285 (insert (x-get-selection 'PRIMARY)) 1285 (insert primary)
1286 (error "No primary selection")))) 1286 (error "No primary selection"))))
1287 1287
1288(defun mouse-kill-ring-save (click) 1288(defun mouse-kill-ring-save (click)
@@ -1577,7 +1577,7 @@ regardless of where you click."
1577 (or mouse-yank-at-point (mouse-set-point click)) 1577 (or mouse-yank-at-point (mouse-set-point click))
1578 (let ((secondary (x-get-selection 'SECONDARY))) 1578 (let ((secondary (x-get-selection 'SECONDARY)))
1579 (if secondary 1579 (if secondary
1580 (insert (x-get-selection 'SECONDARY)) 1580 (insert secondary)
1581 (error "No secondary selection")))) 1581 (error "No secondary selection"))))
1582 1582
1583(defun mouse-kill-secondary () 1583(defun mouse-kill-secondary ()