X-Git-Url: http://git.chise.org/gitweb/?a=blobdiff_plain;f=lisp%2Fnnwfm.el;h=17f2656782df517e27c84f0cb3a6b1dc4f93589f;hb=f8854d2d63092f9543fdd531a12a25e727e9a317;hp=2de45b7e664bf9de871984b1a816a81e31b00930;hpb=d0e319b544eb439c3afd135775d6deaebdea3b49;p=elisp%2Fgnus.git- diff --git a/lisp/nnwfm.el b/lisp/nnwfm.el index 2de45b7..17f2656 100644 --- a/lisp/nnwfm.el +++ b/lisp/nnwfm.el @@ -37,11 +37,9 @@ (require 'gnus) (require 'nnmail) (require 'mm-util) -(eval-when-compile - (ignore-errors - (require 'nnweb))) -;; Report failure to find w3 at load time if appropriate. -(eval '(require 'nnweb)) +(require 'mm-url) +(require 'nnweb) +(autoload 'w3-parse-buffer "w3-parse") (nnoo-declare nnwfm) @@ -117,7 +115,7 @@ (erase-buffer) (setq subject (nth 2 (assq (car elem) topics)) thread-id (nth 0 (assq (car elem) topics))) - (nnweb-insert + (mm-url-insert (concat nnwfm-address (format "Item.asp?GroupID=%d&ThreadID=%d" sid thread-id))) @@ -217,7 +215,7 @@ (deffoo nnwfm-request-list (&optional server) (nnwfm-possibly-change-server nil server) (mm-with-unibyte-buffer - (nnweb-insert + (mm-url-insert (if (string-match "/$" nnwfm-address) (concat nnwfm-address "Group.asp") nnwfm-address)) @@ -234,7 +232,7 @@ (setq description (car (last (nnweb-text (nth 1 row))))) (setq articles (string-to-number - (nnweb-replace-in-string + (gnus-replace-in-string (car (last (nnweb-text (nth 3 row)))) "," ""))) (when (and href (string-match "GroupId=\\([0-9]+\\)" href)) @@ -280,12 +278,12 @@ (while furls (erase-buffer) (push (car furls) fetched-urls) - (nnweb-insert (pop furls)) + (mm-url-insert (pop furls)) (goto-char (point-min)) (while (re-search-forward " wr(" nil t) (forward-char -1) (setq elem (message-tokenize-header - (nnweb-replace-in-string + (gnus-replace-in-string (buffer-substring (1+ (point)) (progn @@ -294,18 +292,19 @@ "\\\\[\"\\\\]" ""))) (push (list (string-to-number (nth 1 elem)) - (nnweb-replace-in-string (nth 2 elem) "\"" "") + (gnus-replace-in-string (nth 2 elem) "\"" "") (string-to-number (nth 5 elem))) forum-contents)) (when (re-search-forward "href=\"\\(Thread.*DateLast=\\([^\"]+\\)\\)" nil t) (setq url (match-string 1) - time (nnwfm-date-to-time (url-unhex-string (match-string 2)))) + time (nnwfm-date-to-time (gnus-url-unhex-string + (match-string 2)))) (when (and (nnwfm-new-threads-p group time) (not (member (setq url (concat nnwfm-address - (nnweb-decode-entities-string url))) + (mm-url-decode-entities-string url))) fetched-urls))) (push url furls)))) ;; The main idea here is to map Gnus article numbers to