From: hmurata Date: Sat, 25 Sep 2004 05:08:17 +0000 (+0000) Subject: (wl-summary-toggle-mime): Added optional argument X-Git-Tag: wl-2_12-root~79 X-Git-Url: http://git.chise.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=c2c72cbaf4d42dec9f1dca3a1987872fabd661cb;p=elisp%2Fwanderlust.git (wl-summary-toggle-mime): Added optional argument `no-mime'. if it is non-nil, call `wl-summary-redisplay-no-mime' with `ask-coding' is non-nil. --- diff --git a/wl/ChangeLog b/wl/ChangeLog index 6829992..ba37e9b 100644 --- a/wl/ChangeLog +++ b/wl/ChangeLog @@ -1,3 +1,9 @@ +2004-09-25 Hiroya Murata + + * wl-summary.el (wl-summary-toggle-mime): Added optional argument + `no-mime'. if it is non-nil, call `wl-summary-redisplay-no-mime' + with `ask-coding' is non-nil. + 2004-09-24 Hiroya Murata * wl-thread.el (wl-thread-set-parent): If parent is a message diff --git a/wl/wl-summary.el b/wl/wl-summary.el index 248b8e0..a9dfcd8 100644 --- a/wl/wl-summary.el +++ b/wl/wl-summary.el @@ -4339,15 +4339,19 @@ Use function list is `wl-summary-write-current-folder-functions'." (wl-summary-redisplay))) (message "No last message."))) -(defun wl-summary-toggle-mime () - "Toggle MIME decoding." - (interactive) - (setq wl-summary-buffer-display-as-is - (not wl-summary-buffer-display-as-is)) - (wl-summary-redisplay) - (wl-summary-update-modeline) - (message "MIME decoding: %s" - (if wl-summary-buffer-display-as-is "OFF" "ON"))) +(defun wl-summary-toggle-mime (&optional no-mime) + "Toggle MIME decoding. +If NO-MIME is non-nil, force displaying the message without MIME decoding +and ask coding-system for the message." + (interactive "P") + (if no-mime + (wl-summary-redisplay-no-mime 'ask-coding) + (setq wl-summary-buffer-display-as-is + (not wl-summary-buffer-display-as-is)) + (wl-summary-redisplay) + (wl-summary-update-modeline) + (message "MIME decoding: %s" + (if wl-summary-buffer-display-as-is "OFF" "ON")))) (defun wl-summary-redisplay (&optional arg) "Redisplay message." @@ -4370,7 +4374,7 @@ If ASK-CODING is non-nil, coding-system for the message is asked." (or (read-coding-system "Coding system: ") elmo-mime-display-as-is-coding-system) elmo-mime-display-as-is-coding-system))) - (wl-summary-redisplay-internal nil nil nil t 'all-header))) + (wl-summary-redisplay-internal nil nil nil 'as-is 'all-header))) (defun wl-summary-redisplay-internal (&optional folder number force-reload as-is all-header)