Add hooks for gcc handling
[gnus] / lisp / gnus-draft.el
index a2a4cd3..13b3cbb 100644 (file)
@@ -1,6 +1,6 @@
 ;;; gnus-draft.el --- draft message support for Gnus
 
-;; Copyright (C) 1997-2011 Free Software Foundation, Inc.
+;; Copyright (C) 1997-2012 Free Software Foundation, Inc.
 
 ;; Author: Lars Magne Ingebrigtsen <larsi@gnus.org>
 ;; Keywords: news
@@ -325,18 +325,9 @@ If DONT-POP is nil, display the buffer after setting it up."
        (error "The draft %s is under edit" file)))))
 
 (defun gnus-draft-clear-marks ()
-  (setq gnus-newsgroup-marked nil
-       gnus-newsgroup-unreads (gnus-uncompress-range
-                               (gnus-active gnus-newsgroup-name)))
-  ;; Mark articles except for deleted ones as unread.
-  (let (rest)
-    (dolist (article gnus-newsgroup-reads)
-      (when (and (consp article)
-                (eq (cdr article) gnus-canceled-mark))
-       (push article rest)
-       (setq gnus-newsgroup-unreads
-             (delq (car article) gnus-newsgroup-unreads))))
-    (setq gnus-newsgroup-reads (nreverse rest))))
+  (setq gnus-newsgroup-reads nil
+       gnus-newsgroup-marked nil
+       gnus-newsgroup-unreads (nndraft-articles)))
 
 (provide 'gnus-draft)