From: morioka Date: Fri, 7 Mar 1997 14:25:21 +0000 (+0000) Subject: (emh-edit-again): modified for new behavior of `mime-edit-again'; Use X-Git-Tag: emh-0_21~37 X-Git-Url: http://git.chise.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=be90564255c1f9f7b870027635ad8aaef403944d;p=elisp%2Femh.git (emh-edit-again): modified for new behavior of `mime-edit-again'; Use as-binary-input-file'. --- diff --git a/emh-comp.el b/emh-comp.el index aa9a110..547faed 100644 --- a/emh-comp.el +++ b/emh-comp.el @@ -7,7 +7,7 @@ ;; Maintainer: MORIOKA Tomohiko ;; Created: 1996/2/29 (separated from tm-mh-e.el) ;; Renamed: 1997/2/21 from tmh-comp.el -;; Version: $Id: emh-comp.el,v 0.1 1997-03-05 13:13:00 morioka Exp $ +;; Version: $Id: emh-comp.el,v 0.2 1997-03-07 14:25:21 morioka Exp $ ;; Keywords: mail composing, MH, MIME, mail ;; This file is part of emh. @@ -219,21 +219,18 @@ See also documentation for `\\[mh-send]' function." (catch 'tag (let* ((from-folder mh-current-folder) (config (current-window-configuration)) - code-conversion (draft (cond ((and mh-draft-folder (equal from-folder mh-draft-folder)) (let ((name (format "draft-%d" msg))) (if (get-buffer name) (throw 'tag (pop-to-buffer name)) ) - (let ((file-coding-system-for-read *noconv*) - (filename + (let ((filename (mh-msg-filename msg mh-draft-folder) )) (set-buffer (get-buffer-create name)) - (insert-file-contents filename) + (as-binary-input-file (insert-file-contents filename)) (setq buffer-file-name filename) - (setq code-conversion t) ) (pop-to-buffer name) (if (re-search-forward "^-+$" nil t) @@ -241,24 +238,20 @@ See also documentation for `\\[mh-send]' function." ) name)) (t - (prog1 - (let ((file-coding-system-for-read *noconv*)) - (mh-read-draft "clean-up" (mh-msg-filename msg) nil) - ) - (setq code-conversion t) - )))) + (as-binary-input-file + (mh-read-draft "clean-up" (mh-msg-filename msg) nil) + ) + ))) ) (goto-char (point-min)) (mh-clean-msg-header (point-min) mh-new-draft-cleaned-headers nil) - (if code-conversion - (let ((cs (detect-coding-region (point-min)(point-max)))) - (set-buffer-file-coding-system - (if (listp cs) - (car cs) - cs)) - )) + (let ((cs (detect-coding-region (point-min)(point-max)))) + (set-buffer-file-coding-system + (if (listp cs) + (car cs) + cs))) (save-buffer) - (mime-edit-again code-conversion t t) + (mime-edit-again nil 'no-separator 'not-turn-on) (goto-char (point-min)) (mh-compose-and-send-mail draft "" from-folder nil nil nil nil nil nil config)