From 5988691b0425d1952aa32734ee4eb0fb8341faf9 Mon Sep 17 00:00:00 2001 From: "Richard M. Stallman" Date: Thu, 25 Nov 2004 03:01:10 +0000 Subject: [PATCH] (compilation-mode-map): Don't inherit from compilation-minor-mode-map; copy its bindings instead. But the menu bar Compile entry now does inherit from compilation-menu-map. --- lisp/progmodes/compile.el | 16 +++++++++++++--- 1 file changed, 13 insertions(+), 3 deletions(-) diff --git a/lisp/progmodes/compile.el b/lisp/progmodes/compile.el index 4d96181a6f4..17ea9277518 100644 --- a/lisp/progmodes/compile.el +++ b/lisp/progmodes/compile.el @@ -1080,14 +1080,24 @@ exited abnormally with code %d\n" (defvar compilation-mode-map (let ((map (make-sparse-keymap))) - (set-keymap-parent map compilation-minor-mode-map) + (define-key map [mouse-2] 'compile-goto-error) + (define-key map "\C-c\C-c" 'compile-goto-error) + (define-key map "\C-m" 'compile-goto-error) + (define-key map "\C-c\C-k" 'kill-compilation) + (define-key map "\M-n" 'compilation-next-error) + (define-key map "\M-p" 'compilation-previous-error) + (define-key map "\M-{" 'compilation-previous-file) + (define-key map "\M-}" 'compilation-next-file) + (define-key map " " 'scroll-up) (define-key map "\^?" 'scroll-down) (define-key map "\C-c\C-f" 'next-error-follow-minor-mode) ;; Set up the menu-bar - (define-key map [menu-bar compilation] - (cons "Compile" (make-sparse-keymap "Compile"))) + (let ((submap (make-sparse-keymap "Compile"))) + (define-key map [menu-bar compilation] + (cons "Compile" submap)) + (set-keymap-parent submap compilation-menu-map)) (define-key map [menu-bar compilation compilation-separator2] '("----" . nil)) (define-key map [menu-bar compilation compilation-grep] -- 2.39.2