* wl-summary.el (wl-summary-forward): Put subject in original
authoryoichi <yoichi>
Mon, 6 Dec 2004 13:05:03 +0000 (13:05 +0000)
committeryoichi <yoichi>
Mon, 6 Dec 2004 13:05:03 +0000 (13:05 +0000)
message buffer as argument of wl-draft-forward.
* wl-draft.el (wl-draft-forward): Decode subject as in
wl-draft-reply.

wl/ChangeLog
wl/wl-draft.el
wl/wl-summary.el

index 6fec881..d06646d 100644 (file)
@@ -1,3 +1,10 @@
+2004-12-06  Yoichi NAKAYAMA  <yoichi@geiin.org>
+
+       * wl-summary.el (wl-summary-forward): Put subject in original
+       message buffer as argument of wl-draft-forward.
+       * wl-draft.el (wl-draft-forward): Decode subject as in
+       wl-draft-reply.
+
 2004-12-05  Yoichi NAKAYAMA  <yoichi@geiin.org>
 
        * wl-fldmgr.el (wl-fldmgr-unsubscribe): Show message if it is not
index 7367f20..5d5e661 100644 (file)
@@ -278,7 +278,13 @@ e.g.
   (let (references parent-folder subject)
     (with-current-buffer summary-buf
       (setq parent-folder (wl-summary-buffer-folder-name)))
-    (setq subject (wl-draft-forward-make-subject original-subject))
+    (with-temp-buffer                  ; to keep raw buffer unibyte.
+      (set-buffer-multibyte default-enable-multibyte-characters)
+      (let ((decoder (mime-find-field-decoder 'Subject 'plain)))
+       (setq subject (wl-draft-reply-make-subject
+                      (if (and original-subject decoder)
+                          (funcall decoder original-subject) original-subject)))))
+    (setq subject (wl-draft-forward-make-subject subject))
     (with-current-buffer (wl-message-get-original-buffer)
       (setq references (nconc
                        (std11-field-bodies '("References" "In-Reply-To"))
index 167debf..4729e29 100644 (file)
@@ -4224,15 +4224,10 @@ Use function list is `wl-summary-write-current-folder-functions'."
        (wl-summary-redisplay-internal folder number))
       (setq mes-buf wl-message-buffer)
       (wl-message-select-buffer mes-buf)
-      ;; get original subject.
-      (if summary-buf
-         (save-excursion
-           (set-buffer summary-buf)
-           (setq subject
-                 (or (elmo-message-entity-field
-                      (elmo-message-entity folder number) 'subject 'decode)
-                     ""))))
       (set-buffer mes-buf)
+      (setq subject (with-current-buffer
+                       wl-message-buffer-original-buffer
+                     (std11-field-body "Subject")))
       (wl-draft-forward subject summary-buf number)
       (with-current-buffer summary-buf (run-hooks 'wl-summary-forward-hook))
       (unless without-setup-hook