Fix a recent change in isearch.el
* lisp/isearch.el (isearch-yank-x-selection): Ignore errors signaled by 'gui-get-primary-selection', to better emulate what 'gui-get-selection' was doing. In particular, 'gui-get-primary-selection' can signal an error on MS-Windows.
This commit is contained in:
parent
0e93029353
commit
5d4056c765
1 changed files with 1 additions and 1 deletions
|
@ -2667,7 +2667,7 @@ always reads a string from the `kill-ring' using the minibuffer."
|
|||
(defun isearch-yank-x-selection ()
|
||||
"Pull current PRIMARY X selection into the search string."
|
||||
(interactive)
|
||||
(isearch-yank-string (gui-get-primary-selection))
|
||||
(isearch-yank-string (ignore-errors (gui-get-primary-selection)))
|
||||
;; If `gui-get-selection' returned the text from the active region,
|
||||
;; then it "used" the mark which we should hence deactivate.
|
||||
(when select-active-regions (deactivate-mark)))
|
||||
|
|
Loading…
Add table
Reference in a new issue