* wl-news.el.in (wl-news-check): Return updating status.
authoryoichi <yoichi>
Fri, 20 Dec 2002 11:06:27 +0000 (11:06 +0000)
committeryoichi <yoichi>
Fri, 20 Dec 2002 11:06:27 +0000 (11:06 +0000)
* wl.el (wl-init): Show message when wl-news-check returns non-nil.

wl/ChangeLog
wl/wl-news.el.in
wl/wl.el

index a34b9d0..2c31be4 100644 (file)
@@ -3,6 +3,8 @@
        * wl-news.el.in (wl-news-send-to-address): New variable.
        (wl-news-send-news): Use it.
        (wl-news-check): Call wl-news-send-news if wl-news-send-to-address.
+       Return updating status.
+       * wl.el (wl-init): Show message when wl-news-check returns non-nil.
 
 2002-12-20  Kenichi OKADA  <okada@opaopa.org>
 
index 1e6d7ae..7b3a763 100644 (file)
   "*The recipient address to send NEWS.")
 
 (defun wl-news-check ()
-  (let ((previous-version (wl-news-previous-version-load))
-       (current-version (product-version (product-find 'wl-version))))
-    (if (and (< 0 (product-version-compare
-                  current-version previous-version))
-            wl-news-lang
-            wl-news-send-to-address
-            (wl-news-send-news previous-version))
-       (wl-news-previous-version-save current-version))))
-
+  (let* ((previous-version (wl-news-previous-version-load))
+        (current-version (product-version (product-find 'wl-version)))
+        (updated (< 0 (product-version-compare
+                       current-version previous-version))))
+    (when updated
+      (and wl-news-lang
+          wl-news-send-to-address
+          (wl-news-send-news previous-version))
+      (wl-news-previous-version-save current-version))
+    updated))
 
 ;;; -*- news-list -*-
 
index ea1807b..6039c2c 100644 (file)
--- a/wl/wl.el
+++ b/wl/wl.el
@@ -697,7 +697,8 @@ Entering Plugged mode calls the value of `wl-plugged-mode-hook'."
          (symbol-value 'wl-summary-subject-filter-function))
     (setq elmo-no-from wl-summary-no-from-message)
     (setq elmo-no-subject wl-summary-no-subject-message)
-    (wl-news-check)
+    (and (wl-news-check)
+        (message "Wanderlust is updated, please read NEWS(.ja) for changes."))
     (setq wl-init t)
     ;; This hook may contain the functions `wl-plugged-init-icons' and
     ;; `wl-biff-init-icons' for reasons of system internal to accord