emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: New Context Menu


From: Juri Linkov
Subject: Re: New Context Menu
Date: Thu, 19 Aug 2021 10:07:30 +0300
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (x86_64-pc-linux-gnu)

>> Once you Copy (or kill) at least once (Either with the menu or with
>> M-w); then the "Paste" appears in the menu automatically the next time
>> you press mouse-3...
>
> Yes.  And that's what I was missing (you said "it's just there", which
> it isn't immediately after entering Emacs).
>
>> The problem is that such "Paste" does not Paste but returns the error I
>> mentioned.
>
> More accurately, the "Paste" menu item appears as soon as there's
> something on the kill-ring, but "Paste" doesn't yank that something,
> instead signaling an error because there's no selection.

Probably it should be replaced with:

diff --git a/lisp/mouse.el b/lisp/mouse.el
index d2a5200d8d..c071fdefac 100644
--- a/lisp/mouse.el
+++ b/lisp/mouse.el
@@ -396,7 +396,7 @@ context-menu-region
                            "\\[ns-copy-including-secondary]"
                          "\\[kill-ring-save]")))
   (define-key-after menu [paste]
-    `(menu-item "Paste" mouse-yank-primary
+    `(menu-item "Paste" mouse-yank-at-click
                 :visible (funcall
                           ',(lambda ()
                               (and (or



reply via email to

[Prev in Thread] Current Thread [Next in Thread]