Index: gnus-srvr.el =================================================================== RCS file: /usr/local/cvsroot/gnus/lisp/gnus-srvr.el,v retrieving revision 7.36 diff -c -r7.36 gnus-srvr.el *** gnus-srvr.el 22 Jan 2009 07:02:16 -0000 7.36 --- gnus-srvr.el 23 Feb 2009 00:09:45 -0000 *************** *** 635,640 **** --- 635,663 ---- ;;; Browse Server Mode ;;; + (defcustom gnus-browse-subscribe-newsgroup-method + 'gnus-subscribe-alphabetically + "Function(s) called when subscribing groups in the Browse Server Buffer + A few pre-made functions are supplied: `gnus-subscribe-randomly' + inserts new groups at the beginning of the list of groups; + `gnus-subscribe-alphabetically' inserts new groups in strict + alphabetic order; `gnus-subscribe-hierarchically' inserts new groups + in hierarchical newsgroup order; `gnus-subscribe-interactively' asks + for your decision; `gnus-subscribe-killed' kills all new groups; + `gnus-subscribe-zombies' will make all new groups into zombies; + `gnus-subscribe-topics' will enter groups into the topics that + claim them." + :group 'gnus-server + :type '(radio (function-item gnus-subscribe-randomly) + (function-item gnus-subscribe-alphabetically) + (function-item gnus-subscribe-hierarchically) + (function-item gnus-subscribe-interactively) + (function-item gnus-subscribe-killed) + (function-item gnus-subscribe-zombies) + (function-item gnus-subscribe-topics) + function + (repeat function))) + (defvar gnus-browse-menu-hook nil "*Hook run after the creation of the browse mode menu.") *************** *** 885,891 **** (gnus-browse-next-group (- n))) (defun gnus-browse-unsubscribe-current-group (arg) ! "(Un)subscribe to the next ARG groups." (interactive "p") (when (eobp) (error "No group at current line")) --- 908,916 ---- (gnus-browse-next-group (- n))) (defun gnus-browse-unsubscribe-current-group (arg) ! "(Un)subscribe to the next ARG groups. ! The variable `gnus-browse-subscribe-newsgroup-method' determines ! how new groups will be entered into the group buffer." (interactive "p") (when (eobp) (error "No group at current line")) *************** *** 934,955 **** ;; subscribe to it. (if (gnus-ephemeral-group-p group) (gnus-kill-ephemeral-group group)) ! ;; We need to discern between killed/zombie groups and ! ;; just unsubscribed ones. ! (gnus-group-change-level ! (or (gnus-group-entry group) ! (list t group gnus-level-default-subscribed ! nil nil (if (gnus-server-equal ! gnus-browse-current-method "native") ! nil ! (gnus-method-simplify ! gnus-browse-current-method)))) ! gnus-level-default-subscribed (gnus-group-level group) ! (and (car (nth 1 gnus-newsrc-alist)) ! (gnus-group-entry (car (nth 1 gnus-newsrc-alist)))) ! (null (gnus-group-entry group))) (delete-char 1) ! (insert ? )) (gnus-group-change-level group gnus-level-unsubscribed gnus-level-default-subscribed) (delete-char 1) --- 959,982 ---- ;; subscribe to it. (if (gnus-ephemeral-group-p group) (gnus-kill-ephemeral-group group)) ! (let ((entry (gnus-group-entry group))) ! (if entry ! ;; Just change the subscription level if it is an ! ;; unsubscribed group. ! (gnus-group-change-level entry ! gnus-level-default-subscribed) ! ;; If it is a killed group or a zombie, feed it to the ! ;; mechanism for new group subscription. ! (gnus-call-subscribe-functions ! gnus-browse-subscribe-newsgroup-method ! group))) (delete-char 1) ! (insert (let ((lvl (gnus-group-level group))) ! (cond ! ((< lvl gnus-level-unsubscribed) ? ) ! ((< lvl gnus-level-zombie) ?U) ! ((< lvl gnus-level-killed) ?Z) ! (t ?K))))) (gnus-group-change-level group gnus-level-unsubscribed gnus-level-default-subscribed) (delete-char 1)