aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorEric S. Raymond1993-04-08 16:35:57 +0000
committerEric S. Raymond1993-04-08 16:35:57 +0000
commit7bc2b98bd80c9ab626df22868fe12acd3f33f4a5 (patch)
tree3660f965b8a997084b78f40e316f223ffd43519b
parente1f297e66c50ca4de958d1eaad156d5a13b37f31 (diff)
downloademacs-7bc2b98bd80c9ab626df22868fe12acd3f33f4a5.tar.gz
emacs-7bc2b98bd80c9ab626df22868fe12acd3f33f4a5.zip
vc-mode: name change.
-rw-r--r--lisp/vc-hooks.el18
1 files changed, 8 insertions, 10 deletions
diff --git a/lisp/vc-hooks.el b/lisp/vc-hooks.el
index dd38a058a37..e3ef44584b0 100644
--- a/lisp/vc-hooks.el
+++ b/lisp/vc-hooks.el
@@ -3,9 +3,7 @@
3;; Copyright (C) 1992 Free Software Foundation, Inc. 3;; Copyright (C) 1992 Free Software Foundation, Inc.
4 4
5;; Author: Eric S. Raymond <esr@snark.thyrsus.com> 5;; Author: Eric S. Raymond <esr@snark.thyrsus.com>
6;; Version: 5.2 6;; Version: 5.3
7
8;; $Id: vc-hooks.el,v 1.10 1993/03/17 14:01:56 eric Exp eric $
9 7
10;; This file is part of GNU Emacs. 8;; This file is part of GNU Emacs.
11 9
@@ -41,11 +39,11 @@ when creating new masters.")
41the make-backup-files variable. Otherwise, prevents backups being made.") 39the make-backup-files variable. Otherwise, prevents backups being made.")
42 40
43;; Tell Emacs about this new kind of minor mode 41;; Tell Emacs about this new kind of minor mode
44(if (not (assoc 'vc-mode-string minor-mode-alist)) 42(if (not (assoc 'vc-mode minor-mode-alist))
45 (setq minor-mode-alist (cons '(vc-mode-string vc-mode-string) 43 (setq minor-mode-alist (cons '(vc-mode vc-mode)
46 minor-mode-alist))) 44 minor-mode-alist)))
47 45
48(make-variable-buffer-local 'vc-mode-string) 46(make-variable-buffer-local 'vc-mode)
49 47
50;; We need a notion of per-file properties because the version 48;; We need a notion of per-file properties because the version
51;; control state of a file is expensive to derive --- we don't 49;; control state of a file is expensive to derive --- we don't
@@ -119,7 +117,7 @@ read-only flag."
119 (toggle-read-only))) 117 (toggle-read-only)))
120 118
121(defun vc-mode-line (file &optional label) 119(defun vc-mode-line (file &optional label)
122 "Set `vc-mode-string' to display type of version control for FILE. 120 "Set `vc-mode' to display type of version control for FILE.
123The value is set in the current buffer, which should be the buffer 121The value is set in the current buffer, which should be the buffer
124visiting FILE." 122visiting FILE."
125 (interactive (list buffer-file-name nil)) 123 (interactive (list buffer-file-name nil))
@@ -129,7 +127,7 @@ visiting FILE."
129 (if (null (current-local-map)) 127 (if (null (current-local-map))
130 (use-local-map (make-sparse-keymap))) 128 (use-local-map (make-sparse-keymap)))
131 (define-key (current-local-map) "\C-x\C-q" 'vc-toggle-read-only) 129 (define-key (current-local-map) "\C-x\C-q" 'vc-toggle-read-only)
132 (setq vc-mode-string 130 (setq vc-mode
133 (concat " " (or label (symbol-name vc-type)))))) 131 (concat " " (or label (symbol-name vc-type))))))
134 ;; force update of mode line 132 ;; force update of mode line
135 (set-buffer-modified-p (buffer-modified-p)) 133 (set-buffer-modified-p (buffer-modified-p))
@@ -163,8 +161,8 @@ Returns t if checkout was successful, nil otherwise."
163 (cons 'vc-file-not-found-hook find-file-not-found-hooks))) 161 (cons 'vc-file-not-found-hook find-file-not-found-hooks)))
164 162
165;;; Now arrange for bindings and autoloading of the main package. 163;;; Now arrange for bindings and autoloading of the main package.
166;;; Bindings for this have to go in the global map, as it may have 164;;; Bindings for this have to go in the global map, as we'll often
167;;; to coexist with a lot of different major modes. 165;;; want to call them from random buffers.
168 166
169(setq vc-prefix-map (lookup-key global-map "\C-xv")) 167(setq vc-prefix-map (lookup-key global-map "\C-xv"))
170(if (not (keymapp vc-prefix-map)) 168(if (not (keymapp vc-prefix-map))