Fix up some issues in Inspector (including mis-spelled identifier). Bug

281165, patch by Frank Wein <bugzilla@mcsmurf.de>, r=timeless, sr=bzbarsky
This commit is contained in:
bzbarsky%mit.edu 2005-02-07 18:03:13 +00:00
Родитель eeabc57b3d
Коммит 933dea016f
4 изменённых файлов: 9 добавлений и 4 удалений

Просмотреть файл

@ -46,6 +46,7 @@
//////////// global variables /////////////////////
var viewer;
var bundle;
//////////// global constants ////////////////////
@ -57,6 +58,7 @@ window.addEventListener("load", JSObjectViewer_initialize, false);
function JSObjectViewer_initialize()
{
bundle = document.getElementById("inspector-bundle");
viewer = new JSObjectViewer();
viewer.initialize(parent.FrameExchange.receiveData(window));
}
@ -90,7 +92,7 @@ JSObjectViewer.prototype =
{
this.mSubject = aObject;
this.emptyTree(this.mTreeKids);
var ti = this.addTreeItem(this.mTreeKids, "target", aObject, aObject);
var ti = this.addTreeItem(this.mTreeKids, bundle.getString("root.title"), aObject, aObject);
this.openTreeItem(ti);
this.mObsMan.dispatchEvent("subjectChange", { subject: aObject });
@ -274,7 +276,7 @@ function getSelectedItem()
{
var tree = document.getElementById("treeJSObject");
if (tree.view.selection.count)
return tree.contentView.getItemAtIndex(tree.curentIndex);
return tree.contentView.getItemAtIndex(tree.currentIndex);
else
return null;
}

Просмотреть файл

@ -17,6 +17,8 @@
<script type="application/x-javascript" src="chrome://inspector/content/hooks.js"/>
<script type="application/x-javascript" src="chrome://inspector/content/utils.js"/>
<stringbundle id="inspector-bundle" src="chrome://inspector/locale/inspector.properties"/>
<commandset>
<command id="cmdCopyValue" oncommand="viewer.cmdCopyValue()"/>
<command id="cmdEvalExpr" oncommand="viewer.cmdEvalExpr()"/>

Просмотреть файл

@ -51,6 +51,7 @@ enterAttrName.message = Enter the attribute name:
enterAttrValue.message = Enter the attribute value:
findNodesDocumentEnd.message = End of document reached.
findNodesDocumentEnd.title = Find Nodes
root.title = Subject
# The following items correspond to the node types defined by the

Просмотреть файл

@ -35,12 +35,12 @@
- ***** END LICENSE BLOCK ***** -->
<!ENTITY jsCopyValue.label "Copy Value">
<!ENTITY jsEval.label "Evaluate Javascript...">
<!ENTITY jsEval.label "Evaluate JavaScript...">
<!ENTITY jsProperty.label "Property">
<!ENTITY jsValue.label "Value">
<!ENTITY jsEval.desc "Enter a javascript expression. The variable &quot;target&quot; is the object that is currently selected. Any value that you return will be displayed in the Javascript Object Viewer.">
<!ENTITY jsEval.desc "Enter a JavaScript expression. The variable &quot;target&quot; is the property that is currently selected. Any value that you return will be displayed in the JavaScript Object Viewer.">
<!ENTITY jsExecute.label "Execute">
<!ENTITY jsCancel.label "Cancel">