From 32a6d52d43b4c3452687a11b01dfb51ba111fee2 Mon Sep 17 00:00:00 2001 From: Po Lu Date: Tue, 21 Jun 2022 09:35:07 +0800 Subject: Move selection delayed message to a better location * lisp/term/x-win.el (gui-backend-get-selection): Remove `with-delayed-message' here. * src/xselect.c (x_display_selection_waiting_message) (x_cancel_atimer): New functions. (x_get_foreign_selection): Add an atimer that displays the message after a while. --- lisp/term/x-win.el | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'lisp') diff --git a/lisp/term/x-win.el b/lisp/term/x-win.el index 6e083499df4..32675a07b1f 100644 --- a/lisp/term/x-win.el +++ b/lisp/term/x-win.el @@ -1366,9 +1366,8 @@ This returns an error if any Emacs frames are X frames." (cl-defmethod gui-backend-get-selection (selection-symbol target-type &context (window-system x) &optional time-stamp terminal) - (with-delayed-message (1 "Waiting for selection") - (x-get-selection-internal selection-symbol target-type - time-stamp terminal))) + (x-get-selection-internal selection-symbol target-type + time-stamp terminal)) ;; Initiate drag and drop (add-hook 'after-make-frame-functions 'x-dnd-init-frame) -- cgit v1.2.3