From 8d1ff3e270d53994fba93ffafd6cc63e4fd511d2 Mon Sep 17 00:00:00 2001 From: Chris Hanson Date: Fri, 2 Jun 2000 01:52:46 +0000 Subject: [PATCH] Show progress when reading MIME body parts. --- v7/src/imail/imail-imap.scm | 34 +++++++++++++++++++++------------- 1 file changed, 21 insertions(+), 13 deletions(-) diff --git a/v7/src/imail/imail-imap.scm b/v7/src/imail/imail-imap.scm index 3e3c69ade..c904763a4 100644 --- a/v7/src/imail/imail-imap.scm +++ b/v7/src/imail/imail-imap.scm @@ -1,6 +1,6 @@ ;;; -*-Scheme-*- ;;; -;;; $Id: imail-imap.scm,v 1.99 2000/06/01 20:08:26 cph Exp $ +;;; $Id: imail-imap.scm,v 1.100 2000/06/02 01:52:46 cph Exp $ ;;; ;;; Copyright (c) 1999-2000 Massachusetts Institute of Technology ;;; @@ -785,18 +785,26 @@ x)) selector))) (imap:response:fetch-body-part - (imap:command:uid-fetch - (imap-folder-connection (message-folder message)) - (imap-message-uid message) - `(',(string-append "body[" - (decorated-string-append - "" "." "" - (map (lambda (x) - (if (exact-nonnegative-integer? x) - (number->string x) - (symbol->string x))) - section)) - "]"))) + (let ((suffix + (string-append + " body part for message " + (number->string (+ (message-index message) 1))))) + ((imail-message-wrapper "Reading" suffix) + (lambda () + (imap:read-literal-progress-hook imail-progress-meter + (lambda () + (imap:command:uid-fetch + (imap-folder-connection (message-folder message)) + (imap-message-uid message) + `(',(string-append "body[" + (decorated-string-append + "" "." "" + (map (lambda (x) + (if (exact-nonnegative-integer? x) + (number->string x) + (symbol->string x))) + section)) + "]")))))))) section #f))) -- 2.25.1