changeset 4668:12289fa93455

Don't clobber existing binding for menu-bar in global-map.
author Roland McGrath <roland@gnu.org>
date Mon, 06 Sep 1993 22:48:00 +0000
parents dbe2da5db2f7
children e212db4385f9
files lisp/menu-bar.el
diffstat 1 files changed, 4 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/lisp/menu-bar.el	Mon Sep 06 22:37:51 1993 +0000
+++ b/lisp/menu-bar.el	Mon Sep 06 22:48:00 1993 +0000
@@ -23,7 +23,10 @@
 
 ;;; Code:
 
-(define-key global-map [menu-bar] (make-sparse-keymap "menu-bar"))
+;; Don't clobber an existing menu-bar keymap, to preserve any menu-bar key
+;; definitions made in loaddefs.el.
+(or (lookup-key global-map [menu-bar])
+    (define-key global-map [menu-bar] (make-sparse-keymap "menu-bar")))
 (defvar menu-bar-help-menu (make-sparse-keymap "Help"))
 ;; Put Help item last.
 (setq menu-bar-final-items '(help))