rem: switch (topic) { case "dl-progress": if (dl.percentComplete == -1) { if (!elt.hasAttribute("progressmode")) elt.setAttribute("progressmode", "undetermined"); if (elt.hasAttribute("progress")) elt.removeAttribute("progress"); } else { elt.setAttribute("progress", dl.percentComplete); if (elt.hasAttribute("progressmode")) elt.removeAttribute("progressmode"); } break; default: elt.onEnd(topic); break; 
add: if (dl.percentComplete == -1) { if (!elt.hasAttribute("progressmode")) elt.setAttribute("progressmode", "undetermined"); if (elt.hasAttribute("progress")) elt.removeAttribute("progress"); 
context:   observe: function(subject, topic, state) {    var dl = subject.QueryInterface(Components.interfaces.nsIDownload);    var elt = document.getElementById(dl.target.path);    switch (topic) {      case "dl-progress":        if (dl.percentComplete == -1) {          if (!elt.hasAttribute("progressmode"))            elt.setAttribute("progressmode", "undetermined");          if (elt.hasAttribute("progress"))            elt.removeAttribute("progress");        }        else {          elt.setAttribute("progress", dl.percentComplete);          if (elt.hasAttribute("progressmode"))            elt.removeAttribute("progressmode");        }            break;      default:        elt.onEnd(topic);        break;    }  }
meta: 9421	/local1/tlutelli/issta_data/temp/all_js/javascript/2006_temp/2006/9421/9a90fd69329163919e8e93ba3d72a613528d60dd/downloadPanel.js/clean/browser/components/downloads/content/downloadPanel.js