rem: updateGlobalCommands(); 
add:     if (gUpdatesOnly) { setElementDisabledByID("cmd_continue", false); document.getElementById("continueDialogButton").focus(); } else updateGlobalCommands(); 
context:   onStateChange: function (aAddon, aState, aValue)  {    const nsIXPIProgressDialog = Components.interfaces.nsIXPIProgressDialog;    var element = this.getElementForAddon(aAddon);    if (!element && aState != nsIXPIProgressDialog.DIALOG_CLOSE)      return;    switch (aState) {      case nsIXPIProgressDialog.DOWNLOAD_START:      case nsIXPIProgressDialog.DOWNLOAD_DONE:      case nsIXPIProgressDialog.INSTALL_START:        break;      case nsIXPIProgressDialog.INSTALL_DONE:        // From nsInstall.h        // SUCCESS        = 0        // REBOOT_NEEDED  = 999        // USER_CANCELLED = -210        if (aValue == 0 || aValue == 999 || aValue == -210)          break;        var xpinstallStrings = document.getElementById("xpinstallStrings");        try {          var msg = xpinstallStrings.getString("error" + aValue);        }        catch (e) {          msg = xpinstallStrings.getFormattedString("unknown.error", [aValue]);        }        var title = getExtensionString("errorInstallTitle");        var message = getExtensionString("errorInstallMsg", [getBrandShortName(),                                                             aAddon.xpiURL, msg]);        var ps = Components.classes["@mozilla.org/embedcomp/prompt-service;1"]                           .getService(Components.interfaces.nsIPromptService);        ps.alert(window, title, message + "\n" + aValue);        break;      case nsIXPIProgressDialog.DIALOG_CLOSE:        // Sort on startup and anytime an add-on is installed or upgraded.        gExtensionManager.sortTypeByProperty(nsIUpdateItem.TYPE_ADDON, "name", true);        updateGlobalCommands();        break;    }  },
meta: 9421	/local1/tlutelli/issta_data/temp/all_js/javascript/2006_temp/2006/9421/edf2315ddfebfc491a3ffa1e206edfc0600c606d/extensions.js/clean/toolkit/mozapps/extensions/content/extensions.js