# HG changeset patch # User Chong Yidong # Date 1223755151 0 # Node ID a4dc0840f5dd6ea538c0c3ffde1745d09626e98e # Parent 05cb109b16cb5dbfe9315a420d3cd5bf6664551e (compilation-mode-tool-bar-map): Initialize it unconditionally. diff -r 05cb109b16cb -r a4dc0840f5dd lisp/progmodes/compile.el --- a/lisp/progmodes/compile.el Sat Oct 11 19:58:49 2008 +0000 +++ b/lisp/progmodes/compile.el Sat Oct 11 19:59:11 2008 +0000 @@ -1471,26 +1471,25 @@ `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)