Merge from trunk:
authoryoichi <yoichi>
Sun, 12 Jan 2003 14:00:03 +0000 (14:00 +0000)
committeryoichi <yoichi>
Sun, 12 Jan 2003 14:00:03 +0000 (14:00 +0000)
* wl-summary.el (wl-summary-goto-folder-subr): Fix logic: set
entity-id when folder is given.
* wl-folder.el (wl-folder-set-current-entity-id): Don't use
save-excursion, use save-selected-window instead.
Select folder buffer window if exists.
Enclose by save-current-buffer.

NEWS
NEWS.ja
wl/ChangeLog
wl/wl-folder.el
wl/wl-summary.el

diff --git a/NEWS b/NEWS
index 8a26a3c..96d9926 100644 (file)
--- a/NEWS
+++ b/NEWS
@@ -3,6 +3,8 @@ Wanderlust NEWS -- User-visible changes in Wanderlust.
 * Changes in 2.10.1 from 2.10.0
   Version 2.10.1 is a bug fix version of 2.10.0.
 
+** Fixed a problem that wl-folder-move-cur-folder doesn't work.
+
 ** Fixed a problem that wl-draft-reedit doesn't work properly on Meadow.
 
 ** Fixed a problem that wl-summary-pack-number doesn't work on Maildir and
diff --git a/NEWS.ja b/NEWS.ja
index 21435ca..486eb0d 100644 (file)
--- a/NEWS.ja
+++ b/NEWS.ja
@@ -3,6 +3,8 @@ Wanderlust NEWS (\e$BF|K\8lHG\e(B) -- User-visible changes in Wanderlust.
 * 2.10.0 \e$B$+$i\e(B 2.10.1 \e$B$X$NJQ99E@\e(B
   2.10.1 \e$B$O\e(B 2.10.0 \e$B$N%P%0=$@5HG$G$9!#\e(B
 
+** wl-folder-move-cur-folder \e$B$,8z$$$F$$$J$+$C$?LdBj$,=$@5$5$l$^$7$?!#\e(B
+
 ** Meadow \e$B>e$G\e(B wl-draft-reedit \e$B$,$&$^$/F0$+$J$$LdBj$,=$@5$5$l$^$7$?!#\e(B
 
 ** wl-summary-pack-number \e$B$,\e(B Maildir \e$B$d\e(B shimbun \e$B%U%)%k%@$GF0$+$J$$\e(B
index a306ff8..4a6a980 100644 (file)
@@ -1,3 +1,13 @@
+2003-01-12  Yoichi NAKAYAMA  <yoichi@eken.phys.nagoya-u.ac.jp>
+
+       Merge from trunk:
+       * wl-summary.el (wl-summary-goto-folder-subr): Fix logic: set
+       entity-id when folder is given.
+       * wl-folder.el (wl-folder-set-current-entity-id): Don't use
+       save-excursion, use save-selected-window instead.
+       Select folder buffer window if exists.
+       Enclose by save-current-buffer.
+
 2003-01-10  TAKAHASHI Kaoru  <kaoru@kaisei.org>
 
        * wl-draft.el (wl-draft-self-reply-p): New function.
index 780cae0..93e2958 100644 (file)
@@ -954,21 +954,21 @@ Optional argument ARG is repeart count."
         (goto-char wl-folder-buffer-cur-point))))
 
 (defun wl-folder-set-current-entity-id (entity-id)
-  (let ((buf (get-buffer wl-folder-buffer-name)))
+  (let* ((buf (get-buffer wl-folder-buffer-name))
+        (buf-win (get-buffer-window buf)))
     (if buf
-       (save-excursion
-         (set-buffer buf)
-         (setq wl-folder-buffer-cur-entity-id entity-id)
-         (setq wl-folder-buffer-cur-path (wl-folder-get-path wl-folder-entity
-                                                             entity-id))
-         (wl-highlight-folder-path wl-folder-buffer-cur-path)
-         (and wl-folder-move-cur-folder
-              wl-folder-buffer-cur-point
-              (goto-char wl-folder-buffer-cur-point))))
-    (if (eq (current-buffer) buf)
-       (and wl-folder-move-cur-folder
-            wl-folder-buffer-cur-point
-            (goto-char wl-folder-buffer-cur-point)))))
+       (save-current-buffer
+         (save-selected-window
+           (if buf-win
+               (select-window buf-win)
+             (set-buffer buf))
+           (setq wl-folder-buffer-cur-entity-id entity-id)
+           (setq wl-folder-buffer-cur-path
+                 (wl-folder-get-path wl-folder-entity entity-id))
+           (wl-highlight-folder-path wl-folder-buffer-cur-path)
+           (and wl-folder-move-cur-folder
+                wl-folder-buffer-cur-point
+                (goto-char wl-folder-buffer-cur-point)))))))
 
 (defun wl-folder-check-current-entity ()
   "Check folder at position.
index 94cdc25..77fc39f 100644 (file)
@@ -2573,15 +2573,15 @@ If ARG, without confirm."
          (if (and interactive wl-summary-recenter)
              (recenter (/ (- (window-height) 2) 2))))))
     ;; set current entity-id
-    (if (and (not folder)
-            (setq entity
-                  (wl-folder-search-entity-by-name (elmo-folder-name-internal
-                                                    folder)
-                                                   wl-folder-entity
-                                                   'folder)))
-       ;; entity-id is unknown.
-       (wl-folder-set-current-entity-id
-        (wl-folder-get-entity-id entity)))
+    (when (and folder
+              (setq entity
+                    (wl-folder-search-entity-by-name
+                     (elmo-folder-name-internal folder)
+                     wl-folder-entity
+                     'folder)))
+      ;; entity-id is unknown.
+      (wl-folder-set-current-entity-id
+       (wl-folder-get-entity-id entity)))
     (when (and wl-summary-lazy-highlight
               wl-on-xemacs)
       (sit-for 0))