-;;; wl-score.el -- Scoring in Wanderlust.
+;;; wl-score.el --- Scoring in Wanderlust.
;; Copyright (C) 1998,1999,2000 Masahiro MURATA <muse@ba2.so-net.ne.jp>
;; Copyright (C) 1998,1999,2000 Yuuichi Teranishi <teranisi@gohome.org>
;; Original codes are gnus-score.el and score-mode.el
;;; Code:
-;;
+;;
(require 'wl-vars)
(defun wl-score-string-index< (a1 a2)
(string-lessp (wl-score-ov-entity-get-by-index (car a1) wl-score-index)
- (wl-score-ov-entity-get-by-index (car a2) wl-score-index)))
+ (wl-score-ov-entity-get-by-index (car a2) wl-score-index)))
(defun wl-score-string-func< (a1 a2)
(string-lessp (funcall wl-score-index (car a1))
(or (and (string-match
(concat "^" (regexp-quote
(expand-file-name
- wl-score-files-dir)))
+ wl-score-files-directory)))
(expand-file-name file))
file)
(expand-file-name
file
- (file-name-as-directory wl-score-files-dir)))))
+ (file-name-as-directory wl-score-files-directory)))))
(cached (assoc file wl-score-cache))
alist)
(if cached
(let ((files (wl-get-assoc-list-value
score-alist folder
(if (not wl-score-folder-alist-matchone) 'all-list)))
- fl f)
+ fl f)
(while (setq f (wl-pop files))
(wl-append
fl
(defun wl-score-change-score-file (file)
"Change current score alist."
(interactive
- (list (read-file-name "Change to score file: " wl-score-files-dir)))
+ (list (read-file-name "Change to score file: " wl-score-files-directory)))
(wl-score-load-file file))
(defun wl-score-default (level)
(count (length alist))
(i 0)
(update-unread nil)
+ wl-summary-unread-message-hook
num score dels visible score-mark mark-alist)
(save-excursion
(message "Updating score...")
;; Update Folder mode
(wl-folder-set-folder-updated (wl-summary-buffer-folder-name)
(list 0
- (wl-summary-count-unread
- mark-alist)
+ (let ((pair
+ (wl-summary-count-unread
+ mark-alist)))
+ (+ (car pair) (cdr pair)))
(length num-db)))
(wl-summary-update-modeline)))
(message "Updating score...done")
(defun wl-score-edit-file (file)
"Edit a score FILE."
(interactive
- (list (read-file-name "Edit score file: " wl-score-files-dir)))
+ (list (read-file-name "Edit score file: " wl-score-files-directory)))
(when (wl-collect-summary)
(wl-score-save))
(let ((winconf (current-window-configuration))