Closed Bug 476698 Opened 13 years ago Closed 13 years ago

Activity Manager: report on 'send later' progress


(Thunderbird :: Mail Window Front End, defect)

Not set


(Not tracked)

Thunderbird 3.0b3


(Reporter: davida, Assigned: standard8)


(Depends on 1 open bug)



(2 files, 4 obsolete files)

The activity manager should probably display the progress of sending, as well as indicate the presence of unsent messages.
Depends on: 477054
Attached image Prototype (obsolete) —
This is something I was able to knock up today. It is hooked into the send later progress - at the moment it just shows how many messages are being sent, not progress on the individual messages.

- I'm expecting future versions to show progress of the actual message sending, but the send later service doesn't support that at the moment.
- It appears that process activities have to have contextType/Text ? or assume that they do even if you don't set it.
- contextType/Text doesn't seem to apply to events
- I've done some work on hooking up plural strings - they need some more work yet, probably once we figure out the full ui.
- This patch addresses the issue of being able to run one instance of a listener (which passes info to activity manager) across the whole application without needing an xpcom service implementation.

- If we show progress of sending individual messages and total progress, would we have one contextType (e.g. "Sending Messages") with the individual message sending below them?

I'll attach the current patch in a moment.
Attached patch WIP v1 (obsolete) — Splinter Review
Note, the patch needs the patch on bug 477054 to work properly.
Attached image Prototype v2 (obsolete) —
Updated prototype with revised text and basic display.

This shows the actual send progress of messages and the fact they have completed.

I'm intending on this being a two-stage process, the first one will just get the basic strings and layout working, then the second will add feedback as to who you sent the message to.
Attachment #360719 - Attachment is obsolete: true
Attachment #360720 - Attachment is obsolete: true
Attached patch WIP v2 (obsolete) — Splinter Review
The patch. I still need to handle error states and check through multiple sends (at the same time), but otherwise it should be working.
Blocks: 440794
No longer depends on: 440794
Attached image Initial Version
Here's the first version I'm proposing to get in before the string freeze. Examples of success, failure and in progress are displayed. Its not perfect - there are some progress updates that need to be shown still (e.g. for copying messages to sent folder), but its a good start for showing what we can do.

The strings shown are what I'm intending will be the fallback. Once I can do a bit more work on the interfaces I should be able to get the current message to the listener, and hence the strings will be "Sent Message to Mark Banner" etc.

Note, this will all only be displayed for send unsent messages at the moment, as that is where we are heading in bug 440794.
Attachment #361400 - Attachment is obsolete: true
Attachment #361401 - Attachment is obsolete: true
Attachment #361507 - Flags: ui-review?(clarkbw)
Attachment #361507 - Attachment is patch: false
Attachment #361507 - Attachment mime type: text/plain → image/png
I'd like to get this in before the string freeze (tonight) if possible, and we'll build on it before and after b2. Asking for sr because of the minor mailnews/ change, pinging several people for review as I'm not sure if bienvenu will want to review this, and I don't know who else is about.

Here's the details:

- If you want to test, you'll need the patches from bug 477680 and bug 476700.
- The send progress/event/warning is enabled only for send later activity.
- This patch lays the foundation for other activity manager patches; we set up a send later listener which then feeds the activity manager UI. This keeps the two areas of code distinct. By loading in via a javascript module, we keep one instance regardless of how many windows we open/load the modules into. This stops duplicate entries/management, we just have to ensure that we load the modules for each window we can startup with.
- There are a couple of fixes to activityManager.js - I realised we'd got a couple of things wrong in the initial patch.
- Not all the strings are in use yet (e.g. the *To), I plan to use them in the next phase which should be before b2 and will give an indication of who the email was sent to.
Attachment #361510 - Flags: superreview?(bienvenu)
Attachment #361510 - Flags: review?(philringnalda)
Attachment #361510 - Flags: review?(mkmelin+mozilla)
Attachment #361510 - Flags: review?(bienvenu)
I'm looking through this and will try to apply/run it soon.

+    let displayText;
+    if (aTo) {
+      displayText = this.bundle.formatStringFromName("sendingMessageTo",
+                                                     [aTo], 1);
+    }
+    else {
+      displayText = this.bundle.GetStringFromName("sendingMessage");
+    }

this can be one statement:

let displayText = aTo ? ...
Attachment #361510 - Flags: review?(philringnalda)
Attachment #361510 - Flags: review?(mkmelin+mozilla)
Comment on attachment 361510 [details] [diff] [review]
[checked in] The fix

David says he's happy reviewing this.
Attachment #361510 - Flags: superreview?(bienvenu)
Attachment #361510 - Flags: superreview+
Attachment #361510 - Flags: review?(bienvenu)
Attachment #361510 - Flags: review+
Comment on attachment 361510 [details] [diff] [review]
[checked in] The fix

r/sr=me, modulo the nit I mentioned before, replaceProcessWithEvent -> _replaceProcessWithEvent, and we'll deal with the fact that clearing the AM list doesn't survive closing and re-opening the AM.
Comment on attachment 361507 [details]
Initial Version

Looks good.  I'm sure we'll have some cleanups later; once we get some testing.
Attachment #361507 - Flags: ui-review?(clarkbw) → ui-review+
Comment on attachment 361510 [details] [diff] [review]
[checked in] The fix

Checked in:

I filed bug 477862 about the clear list button issue.

I'll be leaving this bug open for the hooking up of the To %S part of the strings.

See bug 257942 comment 70 for how to access the activity manager on nightlies if you want to see this in action (note: we only have Mac themes at the moment).
Attachment #361510 - Attachment description: The fix → [checked in] The fix
No longer blocks: activitymgr
Depends on: activitymgr
In bug 440794 we actually went with the subject, rather than who the message was to. Some of the UI was redone as well.

I think this is now fixed - future work on send in background/send later will reshape as necessary, but we don't need to keep this bug open for that.
Closed: 13 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.