From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Glenn Morris Newsgroups: gmane.emacs.devel Subject: Re: minibuffer and current-local-map Date: Sun, 06 Jan 2008 14:36:32 -0500 Message-ID: <0yodby3fwf.fsf@fencepost.gnu.org> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: ger.gmane.org 1199648243 16128 80.91.229.12 (6 Jan 2008 19:37:23 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sun, 6 Jan 2008 19:37:23 +0000 (UTC) Cc: Stephen.Berman@gmx.net, emacs-devel@gnu.org To: Richard Stallman Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Sun Jan 06 20:37:44 2008 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1JBbJX-00084I-DO for ged-emacs-devel@m.gmane.org; Sun, 06 Jan 2008 20:37:43 +0100 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1JBbJA-00037I-Kj for ged-emacs-devel@m.gmane.org; Sun, 06 Jan 2008 14:37:20 -0500 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1JBbIS-0002S0-Uj for emacs-devel@gnu.org; Sun, 06 Jan 2008 14:36:37 -0500 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1JBbIQ-0002Qz-Uw for emacs-devel@gnu.org; Sun, 06 Jan 2008 14:36:36 -0500 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1JBbIQ-0002Qu-Nt for emacs-devel@gnu.org; Sun, 06 Jan 2008 14:36:34 -0500 Original-Received: from fencepost.gnu.org ([140.186.70.10]) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1JBbIQ-0005VT-Em for emacs-devel@gnu.org; Sun, 06 Jan 2008 14:36:34 -0500 Original-Received: from rgm by fencepost.gnu.org with local (Exim 4.60) (envelope-from ) id 1JBbIO-0006bJ-MV; Sun, 06 Jan 2008 14:36:32 -0500 X-Spook: broadside counter terrorism AMEMB INS Crypto AG enigma X-Ran: !cX`Lybl[Bt+7pY1A\Q{@'n+cuGPdu?x{ZqLM6Eflb]rTapT0 List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:86371 Archived-At: I no longer have the original message to reply to. I'm replying to: http://lists.gnu.org/archive/html/emacs-devel/2007-11/msg00602.html From: Richard Stallman Subject: Re: minibuffer and current-local-map Date: Fri, 09 Nov 2007 17:00:03 -0500 The issue is: emacs -Q M-x C-mouse-3 in the minibuffer brings up a menu with two "Minibuff" entries. rms said: The solution, I think, is to fix the menu code to avoid showing duplicates in such a case. Here is a simple patch that just takes the first of any duplicate (same name) menus. *** mouse.el.~1.315.2.4.~ 2007-12-06 20:27:17.000000000 -0800 --- mouse.el 2008-01-06 11:11:51.000000000 -0800 *************** *** 173,183 **** ;; default to the edit menu. (newmap (if ancestor (make-sparse-keymap (concat mode-name " Mode")) ! menu-bar-edit-menu))) (if ancestor ;; Make our menu inherit from the desired keymap which we want ;; to display as the menu now. ! (set-keymap-parent newmap ancestor)) (popup-menu newmap event prefix))) --- 173,190 ---- ;; default to the edit menu. (newmap (if ancestor (make-sparse-keymap (concat mode-name " Mode")) ! menu-bar-edit-menu)) ! uniq) (if ancestor ;; Make our menu inherit from the desired keymap which we want ;; to display as the menu now. ! (set-keymap-parent newmap ! (progn ! (dolist (e ancestor) ! (unless (and (listp e) ! (assoc (car e) uniq)) ! (setq uniq (append uniq (list e))))) ! uniq))) (popup-menu newmap event prefix)))