From: Richard M. Stallman Date: Sat, 17 Jun 1995 23:53:53 +0000 (+0000) Subject: (normal-top-level, command-line-1): X-Git-Tag: emacs-19.34~3559 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=365636dc53147e9a3192f3a19f0b2f176fa1db56;p=emacs.git (normal-top-level, command-line-1): Call precompute-menubar-bindings only if using x. (precompute-menubar-bindings): Don't check for x here. Set define-key-rebound-commands to t. --- diff --git a/lisp/startup.el b/lisp/startup.el index 9b73e40a59d..6b636f54516 100644 --- a/lisp/startup.el +++ b/lisp/startup.el @@ -295,19 +295,20 @@ specified by the LC_ALL, LC_CTYPE and LANG environment variables.") (and window-setup-hook (run-hooks 'window-setup-hook)) (or menubar-bindings-done - (precompute-menubar-bindings)))))) + (if (eq window-system 'x) + (precompute-menubar-bindings))))))) ;; Precompute the keyboard equivalents in the menu bar items. (defun precompute-menubar-bindings () - (if (eq window-system 'x) - (let ((submap (lookup-key global-map [menu-bar]))) - (while submap - (and (consp (car submap)) - (symbolp (car (car submap))) - (stringp (car-safe (cdr (car submap)))) - (keymapp (cdr (cdr (car submap)))) - (x-popup-menu nil (cdr (cdr (car submap))))) - (setq submap (cdr submap)))))) + (let ((submap (lookup-key global-map [menu-bar]))) + (while submap + (and (consp (car submap)) + (symbolp (car (car submap))) + (stringp (car-safe (cdr (car submap)))) + (keymapp (cdr (cdr (car submap)))) + (x-popup-menu nil (cdr (cdr (car submap))))) + (setq submap (cdr submap)))) + (setq define-key-rebound-commands t)) (defun command-line () (setq command-line-default-directory default-directory) @@ -590,7 +591,8 @@ specified by the LC_ALL, LC_CTYPE and LANG environment variables.") (setq window-setup-hook nil) ;; Do this now to avoid an annoying delay if the user ;; clicks the menu bar during the sit-for. - (precompute-menubar-bindings) + (if (eq window-system 'x) + (precompute-menubar-bindings)) (setq menubar-bindings-done t) (unwind-protect (progn