From: hmurata Date: Thu, 9 Oct 2003 10:33:14 +0000 (+0000) Subject: * wl-summary.el (wl-summary-prefetch-msg): Bind wl-message-entity; X-Git-Tag: wl-2_11_19~7 X-Git-Url: http://git.chise.org/gitweb/?a=commitdiff_plain;h=fb1b5e7a593832f70f3600cffe2dacb18ae4fc55;p=elisp%2Fwanderlust.git * wl-summary.el (wl-summary-prefetch-msg): Bind wl-message-entity; Use ignore-errors instead of unwind-protect. --- diff --git a/wl/ChangeLog b/wl/ChangeLog index d6d9914..adbc4e6 100644 --- a/wl/ChangeLog +++ b/wl/ChangeLog @@ -1,3 +1,8 @@ +2003-10-09 Hiroya Murata + + * wl-summary.el (wl-summary-prefetch-msg): Bind wl-message-entity; + Use ignore-errors instead of unwind-protect. + 2003-10-03 Tetsurou Okazaki * wl-thread.el (wl-thread-delete-message): Rewrite the procedure diff --git a/wl/wl-summary.el b/wl/wl-summary.el index 9d55db1..73fbc61 100644 --- a/wl/wl-summary.el +++ b/wl/wl-summary.el @@ -1359,56 +1359,56 @@ If ARG is non-nil, checking is omitted." (null wl-prefetch-threshold) (< size wl-prefetch-threshold)))) mark new-mark) - (unwind-protect - (progn - (when (and (or arg (not file-cached)) - size (not force-read) wl-prefetch-confirm) - (setq force-read - (save-restriction - (widen) - (y-or-n-p - (format - "Message from %s has %d bytes. Prefetch it? " - (concat - "[ " - (save-match-data - (wl-set-string-width - 17 - (funcall - wl-summary-from-function - (elmo-delete-char - ?\" - (or - (elmo-message-entity-field - (elmo-message-entity - wl-summary-buffer-elmo-folder - number) - 'from t) - "??"))))) - " ]") - size)))) - (message "")) ; flush. - (if force-read - (save-excursion - (save-match-data - ;; online - (if (or arg (not file-cached)) - (elmo-message-encache - wl-summary-buffer-elmo-folder - number)) - (elmo-message-set-cached wl-summary-buffer-elmo-folder - number t) - (when (and (wl-summary-jump-to-msg number) - (wl-summary-update-persistent-mark)) - (sit-for 0) - (wl-summary-count-unread) - (wl-summary-update-modeline) - (wl-folder-update-unread - (wl-summary-buffer-folder-name) - (+ wl-summary-buffer-unread-count - wl-summary-buffer-new-count)))) - t) - nil)))))) + (ignore-errors + (when (and (or arg (not file-cached)) + size (not force-read) wl-prefetch-confirm) + (let ((wl-message-entity (elmo-message-entity + wl-summary-buffer-elmo-folder + number))) + (setq force-read + (save-restriction + (widen) + (y-or-n-p + (format + "Message from %s has %d bytes. Prefetch it? " + (concat + "[ " + (save-match-data + (wl-set-string-width + 17 + (funcall + wl-summary-from-function + (elmo-delete-char + ?\" + (or + (elmo-message-entity-field + wl-message-entity + 'from t) + "??"))))) + " ]") + size)))) + (message ""))) ; flush. + (if force-read + (save-excursion + (save-match-data + ;; online + (if (or arg (not file-cached)) + (elmo-message-encache + wl-summary-buffer-elmo-folder + number)) + (elmo-message-set-cached wl-summary-buffer-elmo-folder + number t) + (when (and (wl-summary-jump-to-msg number) + (wl-summary-update-persistent-mark)) + (sit-for 0) + (wl-summary-count-unread) + (wl-summary-update-modeline) + (wl-folder-update-unread + (wl-summary-buffer-folder-name) + (+ wl-summary-buffer-unread-count + wl-summary-buffer-new-count)))) + t) + nil))))) (defsubst wl-summary-narrow-to-region (beg end) (narrow-to-region