[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Emacs-diffs] master cb0f634: Replace uses of the obsolete local-write-f
From: |
Glenn Morris |
Subject: |
[Emacs-diffs] master cb0f634: Replace uses of the obsolete local-write-file-hooks |
Date: |
Thu, 8 Mar 2018 20:05:56 -0500 (EST) |
branch: master
commit cb0f6348956761880069e8ff7ed5086a177a521a
Author: Glenn Morris <address@hidden>
Commit: Glenn Morris <address@hidden>
Replace uses of the obsolete local-write-file-hooks
* lisp/net/quickurl.el (quickurl-reread-hook-postfix):
* lisp/progmodes/ebrowse.el (ebrowse-tree-mode)
(ebrowse-write-file-hook-fn):
* lisp/progmodes/glasses.el (glasses-mode):
* lisp/progmodes/vhdl-mode.el (vhdl-write-file-hooks-init):
* lisp/vc/ediff-merg.el (ediff-set-merge-mode):
* lisp/vc/ediff-util.el (ediff-setup):
Replace local-write-file-hooks, obsolete since 22.1,
with write-file-functions.
---
lisp/net/quickurl.el | 2 +-
lisp/progmodes/ebrowse.el | 4 ++--
lisp/progmodes/glasses.el | 4 ++--
lisp/progmodes/vhdl-mode.el | 4 ++--
lisp/vc/ediff-merg.el | 2 +-
lisp/vc/ediff-util.el | 2 +-
6 files changed, 9 insertions(+), 9 deletions(-)
diff --git a/lisp/net/quickurl.el b/lisp/net/quickurl.el
index abfca38..a5ba26b 100644
--- a/lisp/net/quickurl.el
+++ b/lisp/net/quickurl.el
@@ -155,7 +155,7 @@ could be used here."
(defconst quickurl-reread-hook-postfix
"
;; Local Variables:
-;; eval: (progn (require 'quickurl) (add-hook 'local-write-file-hooks (lambda
() (quickurl-read) nil)))
+;; eval: (progn (require 'quickurl) (add-hook 'write-file-functions (lambda ()
(quickurl-read) nil) nil t))
;; End:
"
"Example `quickurl-postfix' text that adds a local variable to the
diff --git a/lisp/progmodes/ebrowse.el b/lisp/progmodes/ebrowse.el
index ca64af5..08b1acd 100644
--- a/lisp/progmodes/ebrowse.el
+++ b/lisp/progmodes/ebrowse.el
@@ -1107,7 +1107,7 @@ Tree mode key bindings:
(and tree (ebrowse-build-tree-obarray tree)))
(set (make-local-variable 'ebrowse--frozen-flag) nil)
- (add-hook 'local-write-file-hooks 'ebrowse-write-file-hook-fn nil t)
+ (add-hook 'write-file-functions 'ebrowse-write-file-hook-fn nil t)
(modify-syntax-entry ?_ (char-to-string (char-syntax ?a)))
(when tree
(ebrowse-redraw-tree)
@@ -4023,7 +4023,7 @@ If VIEW is non-nil, view else find source files."
(defun ebrowse-write-file-hook-fn ()
"Write current buffer as a class tree.
-Installed on `local-write-file-hooks'."
+Added to `write-file-functions'."
(ebrowse-save-tree)
t)
diff --git a/lisp/progmodes/glasses.el b/lisp/progmodes/glasses.el
index de17601..c3e8ac3 100644
--- a/lisp/progmodes/glasses.el
+++ b/lisp/progmodes/glasses.el
@@ -326,10 +326,10 @@ add virtual separators (like underscores) at places they
belong to."
(if glasses-mode
(progn
(jit-lock-register 'glasses-change)
- (add-hook 'local-write-file-hooks
+ (add-hook 'write-file-functions
'glasses-convert-to-unreadable nil t))
(jit-lock-unregister 'glasses-change)
- (remove-hook 'local-write-file-hooks
+ (remove-hook 'write-file-functions
'glasses-convert-to-unreadable t)))))
diff --git a/lisp/progmodes/vhdl-mode.el b/lisp/progmodes/vhdl-mode.el
index a841f87..f6cb241 100644
--- a/lisp/progmodes/vhdl-mode.el
+++ b/lisp/progmodes/vhdl-mode.el
@@ -4953,8 +4953,8 @@ Key bindings:
(defun vhdl-write-file-hooks-init ()
"Add/remove hooks when buffer is saved."
(if vhdl-modify-date-on-saving
- (add-hook 'local-write-file-hooks 'vhdl-template-modify-noerror nil t)
- (remove-hook 'local-write-file-hooks 'vhdl-template-modify-noerror t))
+ (add-hook 'write-file-functions 'vhdl-template-modify-noerror nil t)
+ (remove-hook 'write-file-functions 'vhdl-template-modify-noerror t))
(if (featurep 'xemacs) (make-local-hook 'after-save-hook))
(add-hook 'after-save-hook 'vhdl-add-modified-file nil t))
diff --git a/lisp/vc/ediff-merg.el b/lisp/vc/ediff-merg.el
index ad72d75..b67f520 100644
--- a/lisp/vc/ediff-merg.el
+++ b/lisp/vc/ediff-merg.el
@@ -194,7 +194,7 @@ Buffer B."
(defun ediff-set-merge-mode ()
(normal-mode t)
- (remove-hook 'local-write-file-hooks 'ediff-set-merge-mode))
+ (remove-hook 'write-file-functions 'ediff-set-merge-mode t))
;; Go over all diffs starting with DIFF-NUM and copy regions into buffer C
diff --git a/lisp/vc/ediff-util.el b/lisp/vc/ediff-util.el
index 8670ba4..be36273 100644
--- a/lisp/vc/ediff-util.el
+++ b/lisp/vc/ediff-util.el
@@ -347,7 +347,7 @@ to invocation.")
(goto-char (point-min))
(funcall (ediff-with-current-buffer buf major-mode))
(widen) ; merge buffer is always widened
- (add-hook 'local-write-file-hooks 'ediff-set-merge-mode nil t)
+ (add-hook 'write-file-functions 'ediff-set-merge-mode nil t)
)))
(setq buffer-read-only nil
ediff-buffer-A buffer-A
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Emacs-diffs] master cb0f634: Replace uses of the obsolete local-write-file-hooks,
Glenn Morris <=