changeset 49167:f8c302d7433b

(emerge-setup-fixed-keymaps): Use command remapping instead of substitute-key-definition.
author Andreas Schwab <schwab@suse.de>
date Sun, 12 Jan 2003 20:46:08 +0000
parents 05ad80e1c6d2
children 92fb2806e140
files lisp/emerge.el
diffstat 1 files changed, 4 insertions(+), 8 deletions(-) [+]
line wrap: on
line diff
--- a/lisp/emerge.el	Sun Jan 12 20:45:19 2003 +0000
+++ b/lisp/emerge.el	Sun Jan 12 20:46:08 2003 +0000
@@ -400,10 +400,8 @@
   ;; Allow emerge-fast-keymap to be referenced indirectly
   (fset 'emerge-fast-keymap emerge-fast-keymap)
   ;; Suppress write-file and save-buffer
-  (substitute-key-definition 'write-file 'emerge-query-write-file
-			     emerge-fast-keymap (current-global-map))
-  (substitute-key-definition 'save-buffer 'emerge-query-save-buffer
-			     emerge-fast-keymap (current-global-map))
+  (define-key emerge-fast-keymap [remap write-file] 'emerge-query-write-file)
+  (define-key emerge-fast-keymap [remap save-buffer] 'emerge-query-save-buffer)
 
   (define-key emerge-basic-keymap [menu-bar] (make-sparse-keymap))
 
@@ -1432,10 +1430,8 @@
   (substitute-key-definition 'save-buffer
 			     'emerge-query-save-buffer
 			     emerge-edit-keymap)
-  (substitute-key-definition 'write-file 'emerge-query-write-file
-			     emerge-edit-keymap (current-global-map))
-  (substitute-key-definition 'save-buffer 'emerge-query-save-buffer
-			     emerge-edit-keymap (current-global-map))
+  (define-key emerge-edit-keymap [remap write-file] 'emerge-query-write-file)
+  (define-key emerge-edit-keymap [remap save-buffer] 'emerge-query-save-buffer)
   (use-local-map emerge-fast-keymap)
   (setq emerge-edit-mode nil)
   (setq emerge-fast-mode t))