2004-09-25 Hiroya Murata <lapis-lazuli@pop06.odn.ne.jp>
+ * wl-summary.el (wl-summary-pick): If call it with prefix
+ argument, set `delete-marks' as non-nil. Pick from only visible
+ messages.
+ (wl-summary-check-target-mark): New function.
+ (wl-summary-target-mark-mark-as-read): Use it.
+ (wl-summary-target-mark-mark-as-unread): Ditto.
+ (wl-summary-target-mark-operation): Ditto.
+ (wl-summary-target-mark-set-flags): Ditto.
+ (wl-summary-target-mark-save): Ditto.
+ (wl-summary-target-mark-pick): Ditto.
+ (wl-summary-target-mark-forward): Ditto.
+ (wl-summary-target-mark-reply-with-citation): Ditto.
+ (wl-summary-target-mark-print): Ditto.
+ (wl-summary-target-mark-uudecode): Ditto.
+
* wl-summary.el (wl-summary-toggle-mime): Added optional argument
`no-mime'. if it is non-nil, call `wl-summary-redisplay-no-mime'
with `ask-coding' is non-nil.
i))
(defun wl-summary-pick (&optional from-list delete-marks)
- (interactive)
+ (interactive "i\nP")
(save-excursion
- (let* ((condition (car (elmo-parse-search-condition
+ (let* ((messages (or from-list
+ (elmo-folder-list-messages
+ wl-summary-buffer-elmo-folder
+ 'visible
+ 'in-msgdb)
+ (error "No messages")))
+ (condition (car (elmo-parse-search-condition
(elmo-read-search-condition
wl-summary-pick-field-default))))
(result (elmo-folder-search wl-summary-buffer-elmo-folder
condition
- from-list))
+ messages))
num)
(if delete-marks
(let ((mlist wl-summary-buffer-target-mark-list))
(or (cadr (memq (current-buffer) buffers))
(car buffers)))))
+(defun wl-summary-check-target-mark ()
+ (when (null wl-summary-buffer-target-mark-list)
+ (error "No marked message")))
+
(defun wl-summary-target-mark-mark-as-read ()
(interactive)
+ (wl-summary-check-target-mark)
(save-excursion
(goto-char (point-min))
(let ((inhibit-read-only t)
(defun wl-summary-target-mark-mark-as-unread ()
(interactive)
+ (wl-summary-check-target-mark)
(save-excursion
(goto-char (point-min))
(let ((inhibit-read-only t)
(wl-summary-unset-mark number)))))
(defun wl-summary-target-mark-operation (flag &optional inverse)
+ (wl-summary-check-target-mark)
(save-excursion
(let ((inhibit-read-only t)
(buffer-read-only nil)
(defun wl-summary-target-mark-set-flags (&optional remove)
(interactive "P")
+ (wl-summary-check-target-mark)
(save-excursion
(let ((inhibit-read-only t)
(buffer-read-only nil)
(defun wl-summary-target-mark-save ()
(interactive)
+ (wl-summary-check-target-mark)
(let ((wl-save-dir
(wl-read-directory-name "Save to directory: "
wl-temporary-file-directory))
(defun wl-summary-target-mark-pick ()
(interactive)
+ (wl-summary-check-target-mark)
(wl-summary-pick wl-summary-buffer-target-mark-list 'delete))
(defun wl-summary-update-persistent-mark (&optional number flags)
(defun wl-summary-target-mark-forward (&optional arg)
(interactive "P")
+ (wl-summary-check-target-mark)
(let ((mlist (nreverse (copy-sequence wl-summary-buffer-target-mark-list)))
(summary-buf (current-buffer))
(wl-draft-forward t)
(defun wl-summary-target-mark-reply-with-citation (&optional arg)
(interactive "P")
+ (wl-summary-check-target-mark)
(let ((mlist (nreverse (copy-sequence wl-summary-buffer-target-mark-list)))
(summary-buf (current-buffer))
change-major-mode-hook
(defun wl-summary-target-mark-print ()
(interactive)
- (if (null wl-summary-buffer-target-mark-list)
- (message "No marked message.")
- (when (y-or-n-p "Print all marked messages. OK? ")
- (while (car wl-summary-buffer-target-mark-list)
- (let ((num (car wl-summary-buffer-target-mark-list)))
- (wl-thread-jump-to-msg num)
- (wl-summary-print-message)
- (wl-summary-unmark))))))
+ (wl-summary-check-target-mark)
+ (when (y-or-n-p "Print all marked messages. OK? ")
+ (while (car wl-summary-buffer-target-mark-list)
+ (let ((num (car wl-summary-buffer-target-mark-list)))
+ (wl-thread-jump-to-msg num)
+ (wl-summary-print-message)
+ (wl-summary-unmark)))))
(defun wl-summary-folder-info-update ()
(wl-folder-set-folder-updated
(defun wl-summary-target-mark-uudecode ()
(interactive)
+ (wl-summary-check-target-mark)
(let ((mlist (reverse wl-summary-buffer-target-mark-list))
(summary-buf (current-buffer))
(tmp-buf (get-buffer-create "*WL UUENCODE*"))