X-Git-Url: http://git.chise.org/gitweb/?a=blobdiff_plain;f=wl%2Fwl-thread.el;h=9c82126a4bbe0bbbae24d7ff46e0401b4d7c1a9c;hb=a188e316446f771a0900c8e05026e39b224eb0f9;hp=585dbd25f6835dca994fae8a45639688b1b8ec91;hpb=44e7e507a90209ffa0cd7d0fd7b5f009e8ff73ce;p=elisp%2Fwanderlust.git diff --git a/wl/wl-thread.el b/wl/wl-thread.el index 585dbd2..9c82126 100644 --- a/wl/wl-thread.el +++ b/wl/wl-thread.el @@ -567,14 +567,12 @@ ENTITY is returned." (wl-thread-reparent-children children top-child) (wl-append update-msgs children)))) ;; delete myself from top list. - (let ((older-brothers (wl-thread-entity-get-older-brothers - entity nil)) - (younger-brothers (wl-thread-entity-get-younger-brothers - entity nil))) - (setq wl-thread-entity-list - (append (append older-brothers - (and top-child (list top-child))) - younger-brothers)))))) + (let ((match (memq msg wl-thread-entity-list))) + (when match + (if top-child + (setcar match top-child) + (setq wl-thread-entity-list + (delq msg wl-thread-entity-list)))))))) ;; (if deep ;; delete thread on buffer @@ -641,19 +639,20 @@ ENTITY is returned." When optional argument UPDATE is non-nil, Message is inserted to the summary buffer." (let ((parent (wl-thread-get-entity parent-msg)) - (depth 0) cur child-entity invisible-top) ;;; Update the thread view...not implemented yet. ;;; (when force-insert ;;; (if parent ;;; (wl-thread-entity-force-open parent)) (when (and wl-summary-max-thread-depth parent) - (setq cur parent) - (while cur - (incf depth) - (setq cur (wl-thread-entity-get-parent-entity cur))) - (when (> depth wl-summary-max-thread-depth) - (setq parent nil))) + (let ((cur parent) + (depth 0)) + (while cur + (incf depth) + (setq cur (wl-thread-entity-get-parent-entity cur))) + (when (> depth wl-summary-max-thread-depth) + (setq parent nil + parent-msg nil)))) (if parent ;; insert as children. (wl-thread-entity-insert-as-children @@ -741,6 +740,14 @@ Message is inserted to the summary buffer." (interactive "P") (wl-thread-call-region-func 'wl-summary-mark-as-important-region arg)) +(defun wl-thread-set-flags (&optional arg) + (interactive "P") + (wl-thread-call-region-func 'wl-summary-set-flags-region arg)) + +(defun wl-thread-mark-as-answered (&optional arg) + (interactive "P") + (wl-thread-call-region-func 'wl-summary-mark-as-answered-region arg)) + (defun wl-thread-unmark (&optional arg) (interactive "P") (wl-thread-call-region-func 'wl-summary-unmark-region arg))