From: Chong Yidong Date: Sat, 11 Oct 2008 19:59:11 +0000 (+0000) Subject: (compilation-mode-tool-bar-map): Initialize it unconditionally. X-Git-Tag: emacs-pretest-23.0.90~2551 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=dac05b9caefa3edec2c3434f4924d864db5c7b27;p=emacs.git (compilation-mode-tool-bar-map): Initialize it unconditionally. --- diff --git a/lisp/progmodes/compile.el b/lisp/progmodes/compile.el index c25c45f356f..f6e15d0ba4e 100644 --- a/lisp/progmodes/compile.el +++ b/lisp/progmodes/compile.el @@ -1471,26 +1471,25 @@ Returns the compilation buffer created." `compilation-minor-mode-map' is a parent of this.") (defvar compilation-mode-tool-bar-map - (if (display-graphic-p) - (let ((map (butlast (copy-keymap tool-bar-map))) - (help (last tool-bar-map))) ;; Keep Help last in tool bar - (tool-bar-local-item - "left-arrow" 'previous-error-no-select 'previous-error-no-select map - :rtl "right-arrow" - :help "Goto previous error") - (tool-bar-local-item - "right-arrow" 'next-error-no-select 'next-error-no-select map - :rtl "left-arrow" - :help "Goto next error") - (tool-bar-local-item - "cancel" 'kill-compilation 'kill-compilation map - :enable '(let ((buffer (compilation-find-buffer))) - (get-buffer-process buffer)) - :help "Stop compilation") - (tool-bar-local-item - "refresh" 'recompile 'recompile map - :help "Restart compilation") - (append map help)))) + (let ((map (butlast (copy-keymap tool-bar-map))) + (help (last tool-bar-map))) ;; Keep Help last in tool bar + (tool-bar-local-item + "left-arrow" 'previous-error-no-select 'previous-error-no-select map + :rtl "right-arrow" + :help "Goto previous error") + (tool-bar-local-item + "right-arrow" 'next-error-no-select 'next-error-no-select map + :rtl "left-arrow" + :help "Goto next error") + (tool-bar-local-item + "cancel" 'kill-compilation 'kill-compilation map + :enable '(let ((buffer (compilation-find-buffer))) + (get-buffer-process buffer)) + :help "Stop compilation") + (tool-bar-local-item + "refresh" 'recompile 'recompile map + :help "Restart compilation") + (append map help))) (put 'compilation-mode 'mode-class 'special)