emacs-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Emacs-diffs] Changes to emacs/lisp/gnus/gnus-topic.el


From: Miles Bader
Subject: [Emacs-diffs] Changes to emacs/lisp/gnus/gnus-topic.el
Date: Fri, 04 Apr 2003 01:22:13 -0500

Index: emacs/lisp/gnus/gnus-topic.el
diff -c emacs/lisp/gnus/gnus-topic.el:1.10 emacs/lisp/gnus/gnus-topic.el:1.11
*** emacs/lisp/gnus/gnus-topic.el:1.10  Fri Nov 29 10:57:52 2002
--- emacs/lisp/gnus/gnus-topic.el       Tue Feb  4 08:06:38 2003
***************
*** 163,169 ****
    (dolist (topic (gnus-current-topics topic))
      (gnus-topic-fold t))
    (gnus-topic-goto-topic topic))
!   
  (defun gnus-current-topic ()
    "Return the name of the current topic."
    (let ((result
--- 163,169 ----
    (dolist (topic (gnus-current-topics topic))
      (gnus-topic-fold t))
    (gnus-topic-goto-topic topic))
! 
  (defun gnus-current-topic ()
    "Return the name of the current topic."
    (let ((result
***************
*** 233,246 ****
         ;; Add this group to the list of visible groups.
         (push (or entry group) visible-groups)))
      (setq visible-groups (nreverse visible-groups))
!     (when recursive 
        (if (eq recursive t)
          (setq recursive (cdr (gnus-topic-find-topology topic))))
        (mapcar (lambda (topic-topology)
!               (setq visible-groups 
!                     (nconc visible-groups 
                             (gnus-topic-find-groups
!                             (caar topic-topology) 
                              level all lowest topic-topology))))
              (cdr recursive)))
      visible-groups))
--- 233,246 ----
         ;; Add this group to the list of visible groups.
         (push (or entry group) visible-groups)))
      (setq visible-groups (nreverse visible-groups))
!     (when recursive
        (if (eq recursive t)
          (setq recursive (cdr (gnus-topic-find-topology topic))))
        (mapcar (lambda (topic-topology)
!               (setq visible-groups
!                     (nconc visible-groups
                             (gnus-topic-find-groups
!                             (caar topic-topology)
                              level all lowest topic-topology))))
              (cdr recursive)))
      visible-groups))
***************
*** 1146,1155 ****
    (gnus-group-list-groups)
    (gnus-topic-goto-topic topic))
  
! ;; FIXME: 
! ;;  1. When the marked groups are overlapped with the process 
  ;;     region, the behavior of move or remove is not right.
! ;;  2. Can't process on several marked groups with a same name, 
  ;;     because gnus-group-marked only keeps one copy.
  
  (defun gnus-topic-move-group (n topic &optional copyp)
--- 1146,1155 ----
    (gnus-group-list-groups)
    (gnus-topic-goto-topic topic))
  
! ;; FIXME:
! ;;  1. When the marked groups are overlapped with the process
  ;;     region, the behavior of move or remove is not right.
! ;;  2. Can't process on several marked groups with a same name,
  ;;     because gnus-group-marked only keeps one copy.
  
  (defun gnus-topic-move-group (n topic &optional copyp)
***************
*** 1158,1164 ****
    (interactive
     (list current-prefix-arg
         (completing-read "Move to topic: " gnus-topic-alist nil t)))
!   (let ((use-marked (and (not n) (not (gnus-region-active-p)) 
                         gnus-group-marked t))
        (groups (gnus-group-process-prefix n))
        (topicl (assoc topic gnus-topic-alist))
--- 1158,1164 ----
    (interactive
     (list current-prefix-arg
         (completing-read "Move to topic: " gnus-topic-alist nil t)))
!   (let ((use-marked (and (not n) (not (gnus-region-active-p))
                         gnus-group-marked t))
        (groups (gnus-group-process-prefix n))
        (topicl (assoc topic gnus-topic-alist))
***************
*** 1185,1191 ****
  (defun gnus-topic-remove-group (&optional n)
    "Remove the current group from the topic."
    (interactive "P")
!   (let ((use-marked (and (not n) (not (gnus-region-active-p)) 
                         gnus-group-marked t))
        (groups (gnus-group-process-prefix n)))
      (mapcar
--- 1185,1191 ----
  (defun gnus-topic-remove-group (&optional n)
    "Remove the current group from the topic."
    (interactive "P")
!   (let ((use-marked (and (not n) (not (gnus-region-active-p))
                         gnus-group-marked t))
        (groups (gnus-group-process-prefix n)))
      (mapcar
***************
*** 1283,1289 ****
    (when (gnus-current-topic)
      (gnus-topic-goto-topic (gnus-current-topic))
      (if permanent
!       (setcar (cddr 
                 (cadr
                  (gnus-topic-find-topology (gnus-current-topic))))
                'hidden))
--- 1283,1289 ----
    (when (gnus-current-topic)
      (gnus-topic-goto-topic (gnus-current-topic))
      (if permanent
!       (setcar (cddr
                 (cadr
                  (gnus-topic-find-topology (gnus-current-topic))))
                'hidden))
***************
*** 1296,1303 ****
    (when (gnus-group-topic-p)
      (if (not permanent)
        (gnus-topic-remove-topic t nil)
!       (let ((topic 
!            (gnus-topic-find-topology 
              (completing-read "Show topic: " gnus-topic-alist nil t))))
        (setcar (cddr (cadr topic)) nil)
        (setcar (cdr (cadr topic)) 'visible)
--- 1296,1303 ----
    (when (gnus-group-topic-p)
      (if (not permanent)
        (gnus-topic-remove-topic t nil)
!       (let ((topic
!            (gnus-topic-find-topology
              (completing-read "Show topic: " gnus-topic-alist nil t))))
        (setcar (cddr (cadr topic)) nil)
        (setcar (cdr (cadr topic)) 'visible)
***************
*** 1312,1318 ****
    (if (not topic)
        (call-interactively 'gnus-group-mark-group)
      (save-excursion
!       (let ((groups (gnus-topic-find-groups topic gnus-level-killed t nil 
                                            recursive)))
        (while groups
          (funcall (if unmark 'gnus-group-remove-mark 'gnus-group-set-mark)
--- 1312,1318 ----
    (if (not topic)
        (call-interactively 'gnus-group-mark-group)
      (save-excursion
!       (let ((groups (gnus-topic-find-groups topic gnus-level-killed t nil
                                            recursive)))
        (while groups
          (funcall (if unmark 'gnus-group-remove-mark 'gnus-group-set-mark)
***************
*** 1558,1564 ****
             (mapcar `(lambda (top)
                        (gnus-topic-sort-topics-1 top ,reverse))
                     (sort (cdr top)
!                          '(lambda (t1 t2) 
                              (string-lessp (caar t1) (caar t2)))))))
        (setcdr top (if reverse (reverse subtop) subtop))))
    top)
--- 1558,1564 ----
             (mapcar `(lambda (top)
                        (gnus-topic-sort-topics-1 top ,reverse))
                     (sort (cdr top)
!                          '(lambda (t1 t2)
                              (string-lessp (caar t1) (caar t2)))))))
        (setcdr top (if reverse (reverse subtop) subtop))))
    top)
***************
*** 1566,1573 ****
  (defun gnus-topic-sort-topics (&optional topic reverse)
    "Sort topics in TOPIC alphabetically by topic name.
  If REVERSE, reverse the sorting order."
!   (interactive 
!    (list (completing-read "Sort topics in : " gnus-topic-alist nil t 
                          (gnus-current-topic))
         current-prefix-arg))
    (let ((topic-topology (or (and topic (cdr (gnus-topic-find-topology topic)))
--- 1566,1573 ----
  (defun gnus-topic-sort-topics (&optional topic reverse)
    "Sort topics in TOPIC alphabetically by topic name.
  If REVERSE, reverse the sorting order."
!   (interactive
!    (list (completing-read "Sort topics in : " gnus-topic-alist nil t
                          (gnus-current-topic))
         current-prefix-arg))
    (let ((topic-topology (or (and topic (cdr (gnus-topic-find-topology topic)))
***************
*** 1579,1586 ****
  
  (defun gnus-topic-move (current to)
    "Move the CURRENT topic to TO."
!   (interactive 
!    (list 
      (gnus-group-topic-name)
      (completing-read "Move to topic: " gnus-topic-alist nil t)))
    (unless (and current to)
--- 1579,1586 ----
  
  (defun gnus-topic-move (current to)
    "Move the CURRENT topic to TO."
!   (interactive
!    (list
      (gnus-group-topic-name)
      (completing-read "Move to topic: " gnus-topic-alist nil t)))
    (unless (and current to)
***************
*** 1613,1619 ****
          ;; Add the group to the topic.
          (nconc (assoc topic gnus-topic-alist) (list newsgroup))
          (throw 'end t))))))
!         
  (provide 'gnus-topic)
  
  ;;; gnus-topic.el ends here
--- 1613,1619 ----
          ;; Add the group to the topic.
          (nconc (assoc topic gnus-topic-alist) (list newsgroup))
          (throw 'end t))))))
! 
  (provide 'gnus-topic)
  
  ;;; gnus-topic.el ends here




reply via email to

[Prev in Thread] Current Thread [Next in Thread]