From: hmurata Date: Mon, 21 Jun 2004 23:15:39 +0000 (+0000) Subject: (wl-summary-target-mark-operation): Add optional X-Git-Tag: wl-2_11_31~92 X-Git-Url: http://git.chise.org/gitweb/?a=commitdiff_plain;h=d368e19a4fe91f37144b260956f81a7b6af9f56e;p=elisp%2Fwanderlust.git (wl-summary-target-mark-operation): Add optional argument `inverse' and use `wl-summary-delete-all-target-marks'. (wl-summary-target-mark-mark-as-important): Refine to toggle mark. (wl-summary-target-mark-mark-as-answered): Likewise. --- diff --git a/wl/ChangeLog b/wl/ChangeLog index aa65cee..02657b4 100644 --- a/wl/ChangeLog +++ b/wl/ChangeLog @@ -1,3 +1,10 @@ +2004-06-21 Hiroya Murata + + * wl-summary.el (wl-summary-target-mark-operation): Add optional + argument `inverse' and use `wl-summary-delete-all-target-marks'. + (wl-summary-target-mark-mark-as-important): Refine to toggle mark. + (wl-summary-target-mark-mark-as-answered): Likewise. + 2004-06-22 Yoichi NAKAYAMA * wl-summary.el (wl-summary-target-mark-forward): Use diff --git a/wl/wl-summary.el b/wl/wl-summary.el index 298b655..24c22eb 100644 --- a/wl/wl-summary.el +++ b/wl/wl-summary.el @@ -2960,26 +2960,34 @@ The mark is decided according to the FOLDER, FLAGS and CACHED." (dolist (number wl-summary-buffer-target-mark-list) (wl-summary-unset-mark number))))) -(defun wl-summary-target-mark-operation (flag) +(defun wl-summary-target-mark-operation (flag &optional inverse) (save-excursion - (goto-char (point-min)) (let ((inhibit-read-only t) (buffer-read-only nil) wl-summary-buffer-disp-msg) (funcall (intern (format "wl-summary-mark-as-%s-internal" flag)) - nil + inverse wl-summary-buffer-target-mark-list) - (dolist (number wl-summary-buffer-target-mark-list) - (wl-summary-unset-mark number))))) + (wl-summary-delete-all-target-marks)))) (defun wl-summary-target-mark-mark-as-important () (interactive) - (wl-summary-target-mark-operation 'important)) + (wl-summary-target-mark-operation + 'important + (and (interactive-p) + (elmo-message-flagged-p wl-summary-buffer-elmo-folder + (car wl-summary-buffer-target-mark-list) + 'important)))) (defun wl-summary-target-mark-mark-as-answered () (interactive) - (wl-summary-target-mark-operation 'answered)) + (wl-summary-target-mark-operation + 'answered + (and (interactive-p) + (elmo-message-flagged-p wl-summary-buffer-elmo-folder + (car wl-summary-buffer-target-mark-list) + 'answered)))) (defun wl-summary-target-mark-set-flags () (interactive)