(gnus-summary-next-group): Semi-exit group first to
authorLars Magne Ingebrigtsen <larsi@gnus.org>
Mon, 17 Mar 2003 15:14:43 +0000 (15:14 +0000)
committerLars Magne Ingebrigtsen <larsi@gnus.org>
Mon, 17 Mar 2003 15:14:43 +0000 (15:14 +0000)
that target group is computed correctly when articles are marked
as read by Xref handling.

lisp/ChangeLog
lisp/gnus-sum.el

index d9927ad..b75d7b3 100644 (file)
@@ -1,5 +1,9 @@
 2003-03-17  Lars Magne Ingebrigtsen  <larsi@gnus.org>
 
+       * gnus-sum.el (gnus-summary-next-group): Semi-exit group first to
+       that target group is computed correctly when articles are marked
+       as read by Xref handling.
+
        * mail-source.el (mail-source-fetch-imap): Pass buffer-name to
        imap-open.
 
index 7900b48..596da96 100644 (file)
@@ -6708,6 +6708,11 @@ previous group instead."
   (let ((current-group gnus-newsgroup-name)
        (current-buffer (current-buffer))
        entered)
+    ;; First we semi-exit this group to update Xrefs and all variables.
+    ;; We can't do a real exit, because the window conf must remain
+    ;; the same in case the user is prompted for info, and we don't
+    ;; want the window conf to change before that...
+    (gnus-summary-exit t)
     (while (not entered)
       ;; Then we find what group we are supposed to enter.
       (set-buffer gnus-group-buffer)
@@ -6732,20 +6737,10 @@ previous group instead."
        (let ((unreads (gnus-group-group-unread)))
          (if (and (or (eq t unreads)
                       (and unreads (not (zerop unreads))))
-                  (progn
-                    ;; Now we semi-exit this group to update Xrefs
-                    ;; and all variables.  We can't do a real exit,
-                    ;; because the window conf must remain the same
-                    ;; in case the user is prompted for info, and we
-                    ;; don't want the window conf to change before
-                    ;; that...
-                    (when (gnus-buffer-live-p current-buffer)
-                      (set-buffer current-buffer)
-                      (gnus-summary-exit t))
-                    (gnus-summary-read-group
-                     target-group nil no-article
-                     (and (buffer-name current-buffer) current-buffer)
-                     nil backward)))
+                  (gnus-summary-read-group
+                   target-group nil no-article
+                   (and (buffer-name current-buffer) current-buffer)
+                   nil backward))
              (setq entered t)
            (setq current-group target-group
                  target-group nil)))))))