diff --git a/mozilla/extensions/help/resources/content/help.js b/mozilla/extensions/help/resources/content/help.js index 4551b1743e2..9bd5e1dca6c 100644 --- a/mozilla/extensions/help/resources/content/help.js +++ b/mozilla/extensions/help/resources/content/help.js @@ -96,13 +96,16 @@ function init() { helpGlossaryPanel = document.getElementById("help-glossary-tree"); helpBrowser = document.getElementById("help-content"); - var params = window.arguments[0].QueryInterface(Components.interfaces.nsIDialogParamBlock); - helpFileURI = params.GetString(0); - helpBaseURI = helpFileURI.substring(0, helpFileURI.lastIndexOf("/")+1); // trailing "/" included. + var helpTopic = defaultTopic; + if ("arguments" in window && window.arguments[0] instanceof Components.interfaces.nsIDialogParamBlock) { + helpFileURI = window.arguments[0].GetString(0); + helpBaseURI = helpFileURI.substring(0, helpFileURI.lastIndexOf("/")+1); // trailing "/" included. + helpTopic = window.arguments[0].GetString(1); + } loadHelpRDF(); - displayTopic(params.GetString(1)); + displayTopic(helpTopic); // move to right end of screen var width = document.documentElement.getAttribute("width");