diff options
| -rw-r--r-- | lisp/term/x-win.el | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/lisp/term/x-win.el b/lisp/term/x-win.el index 53cc73540f7..e394b2859dd 100644 --- a/lisp/term/x-win.el +++ b/lisp/term/x-win.el | |||
| @@ -473,7 +473,6 @@ turn off scroll bars; otherwise, turn on scroll bars." | |||
| 473 | ;;; Also, set the value of X cut buffer 0, for backward compatibility | 473 | ;;; Also, set the value of X cut buffer 0, for backward compatibility |
| 474 | ;;; with older X application. | 474 | ;;; with older X application. |
| 475 | (defun x-select-text (text) | 475 | (defun x-select-text (text) |
| 476 | (x-own-selection text 'cut-buffer0) | ||
| 477 | (x-own-selection text 'clipboard) | 476 | (x-own-selection text 'clipboard) |
| 478 | (x-own-selection text) | 477 | (x-own-selection text) |
| 479 | (setq x-last-selected-text text)) | 478 | (setq x-last-selected-text text)) |
| @@ -482,9 +481,9 @@ turn off scroll bars; otherwise, turn on scroll bars." | |||
| 482 | ;;; with older X applications, this checks cut buffer 0 before | 481 | ;;; with older X applications, this checks cut buffer 0 before |
| 483 | ;;; retrieving the value of the primary selection. | 482 | ;;; retrieving the value of the primary selection. |
| 484 | (defun x-cut-buffer-or-selection-value () | 483 | (defun x-cut-buffer-or-selection-value () |
| 485 | (let ((text (or (x-selection-value 'cut-buffer0) | 484 | (let ((text (or (x-selection-value)))) |
| 486 | (x-selection-value)))) | 485 | (if (or (string= text x-last-selected-text) |
| 487 | (if (string= text x-last-selected-text) | 486 | (string= "")) |
| 488 | nil | 487 | nil |
| 489 | (setq x-last-selected-text nil) | 488 | (setq x-last-selected-text nil) |
| 490 | text))) | 489 | text))) |