Remove dead code
[gnus] / lisp / gnus-sum.el
index b99b2fb..8d17d1f 100644 (file)
@@ -2971,12 +2971,6 @@ When FORCE, rebuild the tool bar."
        (setq gnus-summary-tool-bar-map map))))
   (set (make-local-variable 'tool-bar-map) gnus-summary-tool-bar-map))
 
-(defun gnus-score-set-default (var value)
-  "A version of set that updates the GNU Emacs menu-bar."
-  (set var value)
-  ;; It is the message that forces the active status to be updated.
-  (message ""))
-
 (defun gnus-make-score-map (type)
   "Make a summary score map of type TYPE."
   (if t
@@ -3262,13 +3256,6 @@ The following commands are available:
   "Say whether this article is a sparse article or not."
   `(memq ,article gnus-newsgroup-ancient))
 
-(defun gnus-article-parent-p (number)
-  "Say whether this article is a parent or not."
-  (let ((data (gnus-data-find-list number)))
-    (and (cdr data)              ; There has to be an article after...
-        (< (gnus-data-level (car data)) ; And it has to have a higher level.
-           (gnus-data-level (nth 1 data))))))
-
 (defun gnus-article-children (number)
   "Return a list of all children to NUMBER."
   (let* ((data (gnus-data-find-list number))
@@ -3290,14 +3277,6 @@ The following commands are available:
   "Say whether this article is intangible or not."
   '(get-text-property (point) 'gnus-intangible))
 
-(defun gnus-article-read-p (article)
-  "Say whether ARTICLE is read or not."
-  (not (or (memq article gnus-newsgroup-marked)
-          (memq article gnus-newsgroup-spam-marked)
-          (memq article gnus-newsgroup-unreads)
-          (memq article gnus-newsgroup-unselected)
-          (memq article gnus-newsgroup-dormant))))
-
 ;; Some summary mode macros.
 
 (defmacro gnus-summary-article-number ()
@@ -5683,7 +5662,7 @@ If SELECT-ARTICLES, only select those articles from GROUP."
       ;; Init the dependencies hash table.
       (setq gnus-newsgroup-dependencies
            (gnus-make-hashtable (length articles)))
-      (if (buffer-live-p gnus-group-buffer)
+      (if (gnus-buffer-live-p gnus-group-buffer)
          (gnus-set-global-variables)
        (set-default 'gnus-newsgroup-name gnus-newsgroup-name))
       ;; Retrieve the headers and read them in.
@@ -5931,17 +5910,6 @@ If SELECT-ARTICLES, only select those articles from GROUP."
       (setq articles (cdr articles)))
     out))
 
-(defun gnus-uncompress-marks (marks)
-  "Uncompress the mark ranges in MARKS."
-  (let ((uncompressed '(score bookmark))
-       out)
-    (while marks
-      (if (memq (caar marks) uncompressed)
-         (push (car marks) out)
-       (push (cons (caar marks) (gnus-uncompress-range (cdar marks))) out))
-      (setq marks (cdr marks)))
-    out))
-
 (defun gnus-article-mark-to-type (mark)
   "Return the type of MARK."
   (or (cadr (assq mark gnus-article-special-mark-lists))
@@ -7257,7 +7225,7 @@ If FORCE (the prefix), also save the .newsrc file(s)."
       (gnus-summary-update-info))
     (gnus-close-group group)
     ;; Make sure where we were, and go to next newsgroup.
-    (when (buffer-live-p gnus-group-buffer)
+    (when (buffer-live-p (get-buffer gnus-group-buffer))
       (set-buffer gnus-group-buffer))
     (unless quit-config
       (gnus-group-jump-to-group group))
@@ -7283,7 +7251,7 @@ If FORCE (the prefix), also save the .newsrc file(s)."
          (gnus-kill-buffer buf)))
 
       (setq gnus-current-select-method gnus-select-method)
-      (when (buffer-live-p gnus-group-buffer)
+      (when (gnus-buffer-live-p gnus-group-buffer)
        (set-buffer gnus-group-buffer))
       (if quit-config
          (gnus-handle-ephemeral-exit quit-config)
@@ -7363,7 +7331,7 @@ If FORCE (the prefix), also save the .newsrc file(s)."
   "Handle movement when leaving an ephemeral group.
 The state which existed when entering the ephemeral is reset."
   (if (not (buffer-live-p (car quit-config)))
-      (when (buffer-live-p gnus-group-buffer)
+      (when (gnus-buffer-live-p gnus-group-buffer)
        (gnus-configure-windows 'group 'force))
     (set-buffer (car quit-config))
     (unless (eq (cdr quit-config) 'group)
@@ -7762,10 +7730,6 @@ be displayed."
                                            gnus-buttonized-mime-types)))
     (gnus-summary-select-article nil 'force)))
 
-(defun gnus-summary-set-current-mark (&optional current-mark)
-  "Obsolete function."
-  nil)
-
 (defun gnus-summary-next-article (&optional unread subject backward push)
   "Select the next article.
 If UNREAD, only unread articles are selected.
@@ -8239,9 +8203,17 @@ If NOT-MATCHING, excluding articles that have subjects that match a regexp."
   "Limit the summary buffer to articles that have authors that match a regexp.
 If NOT-MATCHING, excluding articles that have authors that match a regexp."
   (interactive
-   (list (read-string (if current-prefix-arg
-                         "Exclude author (regexp): "
-                       "Limit to author (regexp): "))
+   (list (let* ((header (gnus-summary-article-header))
+               (default (and header (car (mail-header-parse-address
+                                          (mail-header-from header))))))
+          (read-string (concat (if current-prefix-arg
+                                   "Exclude author (regexp"
+                                 "Limit to author (regexp")
+                               (if default
+                                   (concat ", default \"" default "\"): ")
+                                 "): "))
+                       nil nil
+                       default))
         current-prefix-arg))
   (gnus-summary-limit-to-subject from "from" not-matching))
 
@@ -12851,7 +12823,9 @@ If ALL is a number, fetch this number of articles."
              ;; Some nntp servers lie about their active range.  When
              ;; this happens, the active range can be in the millions.
              ;; Use a compressed range to avoid creating a huge list.
-             (gnus-range-difference (list gnus-newsgroup-active) old))
+             (gnus-range-difference
+              (gnus-range-difference (list gnus-newsgroup-active) old)
+              gnus-newsgroup-unexist))
        (setq len (gnus-range-length older))
        (cond
         ((null older) nil)