I started with the animations and added the data gathering via public API's from the downloadmanager as public API's are what I use when I'm writing an add-on for firefox. > a look at how downloads.js (for the existing download manager window) works?
> How does this code relate to the existing download manager window? Did you take Are those to simplify development or they're really for end users to tweak vs having the styles be platform specific? I see that you're scoping things like DownloadBadge.canvas.Īlso, there's some prefs defined. setTimeout with function callbacks instead of javascript strings
spaces around binary operators like =, +, =, !=. General style comments that would make it easier to read in the context of other mozilla code: >+ else if (activeDownloads>99) // too long to display, and unlikely to occur Is there a spec somewhere of how things should behave? For example, there was a bit about showing the infinity symbol:
In particular, there was a comment in the patch re: unknown/undefined file sizes when updating the title/summary. How does this code relate to the existing download manager window? Did you take a look at how downloads.js (for the existing download manager window) works? We already have code that handles that for us. > minute" (though I admit I could change the code.) > The current code would require the strings for "about a minute" or "less than a > It would be nice to have abbreviated strings for hours and minutes in each There's no string for "Click badge for Downloads window" and nothing If you make a patch, I think we have tests that you can copy to get the desired look as well. Most linux ISOs seem to do this in my experience. > knows how many bytes of the file it has, but not percentage completed)
> server doesn't report to me the file size at download time? (so the browser > Oh, and can anyone point me to a page where I can download something and the Neil is the one you want to ask xul:panel questions too. > type "panel." There's some problems with that. > could get the panel to work was to put all the xul objects inside a button with > A XUL panel contains a row with the status of each download.
> don't know how to fix that are mainly related to what I used as a container for > making this into a patch might not be too hard, but there's some bugs I I _think_ I can figure out how to make this a patch instead of an addon, but I'll need the help I described above. Can anyone point me in the right direction? I might be able to figure this one out on my own. Does anyone here have enough XUL experience to suggest an alternative to a button with type "panel" that triggers a XUL panel?Ī second problem: I'm not sure where to get internationalized strings for download time remaining. it's probably related to using a button and making it activate on hover, rather than click, and something stealing focus when the panel is showing. It might also fix the ugliness that Wes is seeing, because the button is larger than the canvas inside it.Īlso, the "click to bring up downloads window" code breaks in Firefox 4 (it requires a click for the button or window to get focus, then a second click to bring up the downloads window). the badge itself could just hang out in the menubar if I could get rid of the button. The only way I could get the panel to work was to put all the xul objects inside a button with type "panel." There's some problems with that.įirst of all, it makes the ugly box you see. 12 years making this into a patch might not be too hard, but there's some bugs I don't know how to fix that are mainly related to what I used as a container for the xul code.Ī XUL panel contains a row with the status of each download.