Open progress dialog function needs one line of code to make it useful - nsDownloadManager.cpp




16 years ago
11 years ago


(Reporter: velcrospud, Assigned: bugzilla)


Firefox Tracking Flags

(Not tracked)



(1 attachment)



16 years ago
User-Agent:       Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.4a) Gecko/20030319 Phoenix/0.5
Build Identifier: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.4a) Gecko/20030319 Phoenix/0.5

Both the Phoenix and Mozilla versions of nsDownloadManager.cpp contain a
function OpenProgressDialogFor but the Phoenix version is missing a line from
the Mozilla version that sets false the cancelDownloadOnClose attribute of the
Progress Dialog.  

This is a enhancement request because to my knowledge nothing in Phoenix
currently uses this function, but it could be used for:

1. A port of Mozilla's download manager window to Phoenix.
2. A new windowed or tabbed download manager for Phoenix or added functionality
to the sidebar.
3. A extension that opens progress dialogs but doesn't want them to cancel the
download when closed.  (Full disclosure: My primary concern as author of the
Download Statusbar)

Why: Needed because currently progress dialogs are the only way to pause a download.

Impact: None.  Will not break anything because again, this function is not
currently used in Phoenix.

Reproducible: Didn't try

Steps to Reproduce:

Comment 1

16 years ago
Created attachment 119540 [details] [diff] [review]

added patch


16 years ago
Attachment #119540 - Attachment description: Line to add to Phoenix's nsDownloadManager.cpp → patch

Comment 2

16 years ago
OK. I understood why you need this function.
The code you mentioned is added to Mozilla because of bug 143072.

But I want to clear one point out to confirm this bug (patch).
In case of Firebird, download stops if you close progress dialog.
I think your patch causes unwilling continuous download, if user clicks close
button with the intention of stopping of download.

What do you think?

Comment 3

16 years ago
It would't be a problem.  The OpenProgressDialogFor function is only used to
open the progress dialogs as an information window in conjunction with another
download manager (which would still show the download).  If the user is
defaulting to open progress dialogs when a download starts, this function is not
used to open them, so the download would cancel as expected.

With that said, I was thinking of closing this bug.  If they port the mozilla
download manager to firebird, they are going to need to make this change anyway,
but I'm probably not going to use this function now in my extension.  I was able
to implement pause/resume in much the same (very inefficient) way that the
progress dialogs do.  The firebird download system is probably due for a small
overhaul anyway.  

Comment 4

16 years ago
Closed.  Not needed unless there is a port of mozilla's download manager.
Last Resolved: 16 years ago
Resolution: --- → INVALID

Comment 5

16 years ago
Mass-verifying INVAs.
Product: Firefox → Toolkit
You need to log in before you can comment on or make changes to this bug.