From: hmurata Date: Fri, 12 Nov 2004 15:58:09 +0000 (+0000) Subject: (wl-draft-create-buffer): Bind X-Git-Tag: wl-2_12-root~40 X-Git-Url: http://git.chise.org/gitweb/?a=commitdiff_plain;h=3daf4028af08e7054dff6d7d920b2aa4a76a0963;p=elisp%2Fwanderlust.git (wl-draft-create-buffer): Bind `change-major-mode-hook' after current buffer is changed. --- diff --git a/wl/ChangeLog b/wl/ChangeLog index 4139bc6..5ae69ac 100644 --- a/wl/ChangeLog +++ b/wl/ChangeLog @@ -1,5 +1,8 @@ 2004-11-12 Hiroya Murata + * wl-draft.el (wl-draft-create-buffer): Bind + `change-major-mode-hook' after current buffer is changed. + * wl-summary.el (wl-summary-buffer-detach): New function. (wl-summary-buffer-set-folder): Call it. (wl-summary-mode): Add `wl-summary-buffer-detach' to diff --git a/wl/wl-draft.el b/wl/wl-draft.el index 4c26bc3..543fb62 100644 --- a/wl/wl-draft.el +++ b/wl/wl-draft.el @@ -1705,8 +1705,7 @@ If KILL-WHEN-DONE is non-nil, current draft buffer is killed" (eq this-command 'wl-summary-forward) (eq this-command 'wl-summary-target-mark-forward) (eq this-command 'wl-summary-target-mark-reply-with-citation))) - (buffer (generate-new-buffer "*draft*")) ; Just for initial name. - change-major-mode-hook) + (buffer (generate-new-buffer "*draft*"))) ; Just for initial name. (set-buffer buffer) ;; switch-buffer according to draft buffer style. (if wl-draft-use-frame @@ -1742,7 +1741,8 @@ If KILL-WHEN-DONE is non-nil, current draft buffer is killed" (funcall wl-draft-buffer-style buffer) (error "Invalid value for wl-draft-buffer-style")))))) (auto-save-mode -1) - (wl-draft-mode) + (let (change-major-mode-hook) + (wl-draft-mode)) (set-buffer-multibyte t) ; draft buffer is always multibyte. (make-local-variable 'truncate-partial-width-windows) (setq truncate-partial-width-windows nil)