X-Git-Url: http://git.chise.org/gitweb/?a=blobdiff_plain;f=mixi.el;h=501d0a0675f795c45798f9184d23bb7da4126f41;hb=84345397ddfa6530638c1467e3543c3268ff46e4;hp=b0ee69ed2c67b8430c9ccd1d6637eb6e5f343c4f;hpb=94409b948c5b2330fd4f19ed26d9423539044bb7;p=elisp%2Fmixi.git diff --git a/mixi.el b/mixi.el index b0ee69e..501d0a0 100644 --- a/mixi.el +++ b/mixi.el @@ -1,6 +1,6 @@ ;; mixi.el --- API libraries for accessing to mixi -*- coding: euc-jp -*- -;; Copyright (C) 2005, 2006, 2007 OHASHI Akira +;; Copyright (C) 2005, 2006, 2007, 2008 OHASHI Akira ;; Author: OHASHI Akira ;; Keywords: hypermedia @@ -138,7 +138,7 @@ (autoload 'w3m-retrieve "w3m") (autoload 'url-retrieve-synchronously "url")) -(defconst mixi-revision "$Revision: 1.179 $") +(defconst mixi-revision "$Revision: 1.183 $") (defgroup mixi nil "API library for accessing to mixi." @@ -475,7 +475,8 @@ Increase this value when unexpected error frequently occurs." (let ((page 1) ids) (catch 'end - (while (or (null range) (< (length ids) range)) + (while (and (or (null range) (< (length ids) range)) + (or (= page 1) (and (stringp url) (string-match "%d" url)))) (with-mixi-retrieve (when url (format url page)) (let ((func (if reverse (progn (goto-char (point-max)) @@ -2191,7 +2192,7 @@ Increase this value when unexpected error frequently occurs." ;;;###autoload (defun mixi-get-bbses (community &optional range) - "Get bbese of COMMUNITY." + "Get bbses of COMMUNITY." (unless (mixi-community-p community) (signal 'wrong-type-argument (list 'mixi-community-p community))) (let ((items (mixi-get-matched-items (mixi-bbs-list-page community) @@ -2353,7 +2354,7 @@ Increase this value when unexpected error frequently occurs." ;; FIXME: Split regexp to time, owner(id and nick) and contents. (defconst mixi-event-comment-list-regexp - "
\\(\\|\\) + "
\\(\\|\\) \\([0-9]+\\)ǯ\\([0-9]+\\)·î\\([0-9]+\\)Æü \\([0-9]+\\):\\([0-9]+\\)
@@ -2836,21 +2837,19 @@ Increase this value when unexpected error frequently occurs." "&media_id=" (mixi-news-media-id ,news))) (defconst mixi-news-finished-regexp - "¿½¤·Ìõ¤´¤¶¤¤¤Þ¤»¤ó¤¬¡¢¤³¤Î¥Ë¥å¡¼¥¹¤Ï·ÇºÜ¤¬½ªÎ»¤·¤¿¤«¡¢URL¤¬´Ö°ã¤Ã¤Æ¤¤¤¤¤ë¤¿¤á¤´Í÷¤¤¤¿¤À¤±¤Þ¤»¤ó¡£") + "

¢¨¿½¤·Ìõ¤¢¤ê¤Þ¤»¤ó¤¬¡¢¤³¤Î¥Ë¥å¡¼¥¹¤Ï·ÇºÜ´ü´Ö¤¬½ªÎ»¤·¤¿¤«¡¢URL¤¬´Ö°ã¤Ã¤Æ¤¤¤ë¤¿¤á¤´Í÷¤¤¤¿¤À¤±¤Þ¤»¤ó¡£¾Ü¤·¤¯¤Ï¤³¤Á¤é¤ò¤´Í÷¤¯¤À¤µ¤¤¡£

") (defconst mixi-news-title-regexp - "\\(.+\\)\\( -\\)?") + "
+

\\(.+\\)

") (defconst mixi-news-media-time-regexp - "(\\(.+\\) - \\([0-9]+\\)·î\\([0-9]+\\)Æü \\([0-9]+\\):\\([0-9]+\\))") + "

¡Ê\\(.+\\) - \\([0-9]+\\)·î\\([0-9]+\\)Æü \\([0-9]+\\):\\([0-9]+\\)¡Ë

") (defconst mixi-news-content-regexp - " - + "
\\(.+\\) -
-\\(.* -\\)? -\\(\\|
\\)") + +\\(
+
\\|
\\)") (defun mixi-realize-news (news) "Realize a NEWS." @@ -2983,14 +2982,9 @@ Increase this value when unexpected error frequently occurs." "&type=bn")) (defconst mixi-news-list-regexp - " -¡¦ -\\(.+\\) -\\(\\|\\) - - -\\(.+\\) -\\([0-9]+\\)·î\\([0-9]+\\)Æü \\([0-9]+\\):\\([0-9]+\\)") + "

¡¦ \\(.+\\)\"\"

+\\(.+\\) +\\([0-9]+\\)·î\\([0-9]+\\)Æü \\([0-9]+\\):\\([0-9]+\\)") ;;;###autoload (defun mixi-get-news (category sort &optional range) @@ -3005,17 +2999,17 @@ Increase this value when unexpected error frequently occurs." (year (nth 5 (decode-time (current-time)))) (month (nth 4 (decode-time (current-time))))) (mapcar (lambda (item) - (let ((month-of-item (string-to-number (nth 6 item)))) + (let ((month-of-item (string-to-number (nth 4 item)))) (when (> month-of-item month) (decf year)) (setq month month-of-item) - (mixi-make-news (nth 2 item) (nth 1 item) (nth 5 item) + (mixi-make-news (nth 1 item) (nth 0 item) (nth 3 item) (encode-time - 0 (string-to-number (nth 9 item)) - (string-to-number (nth 8 item)) - (string-to-number (nth 7 item)) + 0 (string-to-number (nth 7 item)) + (string-to-number (nth 6 item)) + (string-to-number (nth 5 item)) month year) - (nth 3 item)))) + (nth 2 item)))) items))) (provide 'mixi)