Commit 64663f06 authored by Stefan Monnier's avatar Stefan Monnier
Browse files

(clone-indirect-buffer-hook): New hook.

(clone-indirect-buffer): Run it.
parent 5a8d03e9
......@@ -482,6 +482,7 @@ Use `(format-mode-line mode-name)' to ensure a string value.
* Lisp Changes in Emacs 23.1
** clone-indirect-buffer now runs the clone-indirect-buffer-hook.
** `beginning-of-defun-function' now takes one argument, the count
given to `beginning-of-defun'.
......
2008-02-12 Stefan Monnier <monnier@iro.umontreal.ca>
* simple.el (clone-indirect-buffer-hook): New hook.
(clone-indirect-buffer): Run it.
2008-02-11 Daiki Ueno <ueno@unixuser.org>
 
* epa.el (epa-menu-mode): Merge into epa-mode.
......@@ -5,8 +10,8 @@
"Encryption/Decryption".
 
* epa-dired.el: Define a new minor-mode epa-dired-mode for dired.
(epa-dired-mode-map): Renamed from epa-dired-map.
(epa-global-dired-mode): Renamed the global minor mode.
(epa-dired-mode-map): Rename from epa-dired-map.
(epa-global-dired-mode): Rename the global minor mode.
 
2008-02-11 Drew Adams <drew.adams@oracle.com>
 
......
......@@ -5547,6 +5547,9 @@ PREFIX is the string that represents this modifier in an event type symbol."
(defvar clone-buffer-hook nil
"Normal hook to run in the new buffer at the end of `clone-buffer'.")
(defvar clone-indirect-buffer-hook nil
"Normal hook to run in the new buffer at the end of `clone-indirect-buffer'.")
(defun clone-process (process &optional newname)
"Create a twin copy of PROCESS.
If NEWNAME is nil, it defaults to PROCESS' name;
......@@ -5692,6 +5695,8 @@ front of the list of recently selected ones."
(setq newname (substring newname 0 (match-beginning 0))))
(let* ((name (generate-new-buffer-name newname))
(buffer (make-indirect-buffer (current-buffer) name t)))
(with-current-buffer buffer
(run-hooks 'clone-indirect-buffer-hook))
(when display-flag
(pop-to-buffer buffer norecord))
buffer))
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment