]> code.delx.au - gnu-emacs/blobdiff - lisp/hexl.el
(Info-goto-index): One register one step in the history.
[gnu-emacs] / lisp / hexl.el
index 1f65ca8309e5a504309873b3f8d74d5a1073a0ce..6a4408e4d4ec9142179e934205dc12ac9352877f 100644 (file)
@@ -254,10 +254,8 @@ You can use \\[hexl-find-file] to visit a file in Hexl mode.
     (setq require-final-newline nil)
 
     ;; Add hooks to rehexlify or dehexlify on various events.
-    (make-local-hook 'after-revert-hook)
     (add-hook 'after-revert-hook 'hexl-after-revert-hook nil t)
 
-    (make-local-hook 'change-major-mode-hook)
     (add-hook 'change-major-mode-hook 'hexl-maybe-dehexlify-buffer nil t)
 
     (if hexl-follow-ascii (hexl-follow-ascii 1)))
@@ -835,8 +833,6 @@ Customize the variable `hexl-follow-ascii' to disable this feature."
                  (> (prefix-numeric-value arg) 0)
               (not hexl-ascii-overlay))))
 
-    (make-local-hook 'post-command-hook)
-                   
     (if on-p
       ;; turn it on
       (if (not hexl-ascii-overlay)
@@ -866,12 +862,12 @@ Customize the variable `hexl-follow-ascii' to disable this feature."
 
 (if hexl-mode-map
     nil
-  (setq hexl-mode-map (copy-keymap (current-global-map)))
+  (setq hexl-mode-map (make-keymap))
   ;; Make all self-inserting keys go through hexl-self-insert-command,
   ;; because we need to convert them to unibyte characters before
   ;; inserting them into the buffer.
   (substitute-key-definition 'self-insert-command 'hexl-self-insert-command
-                            hexl-mode-map)
+                            hexl-mode-map (current-global-map))
 
   (define-key hexl-mode-map [left] 'hexl-backward-char)
   (define-key hexl-mode-map [right] 'hexl-forward-char)