зеркало из https://github.com/mozilla/gecko-dev.git
Fix for 48450. r=morse
This commit is contained in:
Родитель
d854d084a2
Коммит
36d75d26c9
|
@ -120,27 +120,17 @@ function AppendStringToTreelist(tree, string)
|
|||
{
|
||||
if (tree)
|
||||
{
|
||||
var treechildren = tree.firstChild;
|
||||
if (!treechildren)
|
||||
{
|
||||
treechildren = document.createElementNS("http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul", "treechildren");
|
||||
if (treechildren)
|
||||
tree.appendChild(treechildren);
|
||||
else
|
||||
{
|
||||
dump("Failed to create <treechildren>\n");
|
||||
return null;
|
||||
}
|
||||
}
|
||||
var treechildren = document.getElementById('child');
|
||||
|
||||
var treeitem = document.createElementNS("http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul", "treeitem");
|
||||
var treerow = document.createElementNS("http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul", "treerow");
|
||||
var treecell = document.createElementNS("http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul", "treecell");
|
||||
if (treeitem && treerow && treecell)
|
||||
{
|
||||
treecell.setAttribute("value", string);
|
||||
treerow.appendChild(treecell);
|
||||
treeitem.appendChild(treerow);
|
||||
treechildren.appendChild(treeitem)
|
||||
treecell.setAttribute("value", string);
|
||||
var len = Number(tree.getAttribute("length"));
|
||||
if (!len) len = -1;
|
||||
tree.setAttribute("length",len+1);
|
||||
|
|
|
@ -36,7 +36,12 @@ Contributor(s): ______________________________________. -->
|
|||
<box align="vertical" style="width: 24em;margin: 5px;">
|
||||
<text id="info.txt" class="label"/>
|
||||
<box orient="vertical">
|
||||
<tree rows="4" class="list" id="list" flex="1"/>
|
||||
<tree rows="4" class="list" id="list" flex="1">
|
||||
<treecolgroup>
|
||||
<treecol flex="1"/>
|
||||
</treecolgroup>
|
||||
<treechildren flex="1" id="child"/>
|
||||
</tree>
|
||||
</box>
|
||||
</box>
|
||||
<box id="okCancelButtons"/>
|
||||
|
|
Загрузка…
Ссылка в новой задаче