callback returns nil. Return a progress counter instead of t whenever
a start callback was called.
(null elmo-progress-counter))
(let ((counter (cons label (vector 0 total action))))
(elmo-progress-call-callback counter 'start)
- (setq elmo-progress-counter
- (if (elmo-progress-call-callback counter 'query)
- (progn
- (elmo-progress-call-callback counter)
- counter)
- t)))))
+ (when (elmo-progress-call-callback counter 'query)
+ (elmo-progress-call-callback counter)
+ (setq elmo-progress-counter counter))
+ counter)))
(defun elmo-progress-done (counter)
(when counter