(let ((entity (wl-thread-get-entity msg))
top-child top-entity update-msgs invisible-top)
(setq wl-summary-buffer-number-list
- (delq msg wl-summary-buffer-number-list))
+ (delq msg wl-summary-buffer-number-list))
(when entity
(let ((parent (wl-thread-entity-get-parent-entity entity)))
(if parent
(i 0)
beg)
(while top-list
- (when (or (zerop (% i 5)) (= i num))
- (elmo-display-progress
- 'wl-thread-update-indent-string-thread
- "Updating thread indent..."
- (/ (* i 100) num)))
+ (when (> num elmo-display-progress-threshold)
+ (setq i (1+ i))
+ (when (or (zerop (% i 5)) (= i num))
+ (elmo-display-progress
+ 'wl-thread-update-indent-string-thread
+ "Updating thread indent..."
+ (/ (* i 100) num))))
(when (car top-list)
(wl-summary-jump-to-msg (car top-list))
(setq beg (point))
(wl-thread-goto-bottom-of-sub-thread)
(wl-thread-update-indent-string-region beg (point)))
- (setq top-list (cdr top-list)
- i (1+ i)))
+ (setq top-list (cdr top-list)))
(message "Updating thread indent...done")))
(defun wl-thread-update-children-number (entity)
(incf depth)
(setq entity (wl-thread-get-entity number)))
depth))
-
+
(defun wl-thread-update-indent-string-region (beg end)
(interactive "r")
(save-excursion
(wl-thread-entity-set-children
dst-parent-entity
(append children (list number)))
- (wl-thread-entity-set-linked entity t))
+ (wl-thread-entity-set-linked
+ entity
+ (let ((parent (elmo-message-entity-parent
+ wl-summary-buffer-elmo-folder
+ (elmo-message-entity
+ wl-summary-buffer-elmo-folder
+ number))))
+ (or (null parent)
+ (/= parent-number (elmo-message-entity-number parent))))))
;; insert as top
(wl-append wl-thread-entity-list (list number))
(wl-thread-entity-set-linked entity nil))