From: kaoru Date: Fri, 1 Jan 2010 11:35:58 +0000 (+0000) Subject: * wl-score.el (wl-score-insert-help, wl-score-edit-get-header) X-Git-Tag: elmo-imap4-compliance-root~71 X-Git-Url: http://git.chise.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=10867a79220408e6d15bc93ac6cbdd5531f61596;p=elisp%2Fwanderlust.git * wl-score.el (wl-score-insert-help, wl-score-edit-get-header) (wl-score-edit-insert-number): Suppress compile warnings; Use `with-current-buffer' instead of `save-excursion' & `set-buffer'. --- diff --git a/wl/ChangeLog b/wl/ChangeLog index 08b4eab..0024bf6 100644 --- a/wl/ChangeLog +++ b/wl/ChangeLog @@ -18,6 +18,8 @@ * wl-draft.el (wl-draft-add-in-reply-to, wl-draft-delete): Ditto. * wl-draft.el (wl-draft-send-mail-with-smtp, wl-draft-send) (wl-draft-do-fcc): Ditto. + * wl-score.el (wl-score-insert-help, wl-score-edit-get-header) + (wl-score-edit-insert-number): Ditto. * wl-draft.el (wl-draft-do-fcc): Use `with-temp-buffer'. diff --git a/wl/wl-score.el b/wl/wl-score.el index 2010fec..4b6f329 100644 --- a/wl/wl-score.el +++ b/wl/wl-score.el @@ -937,8 +937,7 @@ Set `wl-score-cache' nil." (setq wl-score-help-winconf (current-window-configuration)) (let ((cur-win (selected-window)) mes-win) - (save-excursion - (set-buffer (get-buffer-create "*Score Help*")) + (with-current-buffer (get-buffer-create "*Score Help*") (buffer-disable-undo (current-buffer)) (delete-windows-on (current-buffer)) (erase-buffer) @@ -1374,8 +1373,7 @@ Entering Score mode calls the value of `wl-score-mode-hook'." (let ((sum-buf (wl-score-edit-get-summary-buf)) (index (nth 2 (assoc header wl-score-header-index)))) (when (and sum-buf index) - (save-excursion - (set-buffer sum-buf) + (with-current-buffer sum-buf (wl-score-get-header header extra))))) (defun wl-score-edit-insert-number () @@ -1383,8 +1381,7 @@ Entering Score mode calls the value of `wl-score-mode-hook'." (let ((sum-buf (wl-score-edit-get-summary-buf)) num) (when sum-buf - (if (setq num (save-excursion - (set-buffer sum-buf) + (if (setq num (with-current-buffer sum-buf (wl-summary-message-number))) (prin1 num (current-buffer))))))