Bug 1451282 - Don't use a groupbox for the meta tree in the Page Info window. r=bgrins

This also aligns the help button to the bottom of the window even when the meta tree is hidden.

MozReview-Commit-ID: GCmgThN569z

--HG--
extra : rebase_source : 0dba1f8b8f84d5d97706a283560a3a3c6d7278d8
This commit is contained in:
Paolo Amadini 2018-04-06 13:24:49 +01:00
parent 398807e119
commit 9a7234a00d
7 changed files with 7 additions and 97 deletions

View File

@ -471,21 +471,6 @@ function loadTab(args) {
radioGroup.focus();
}
function toggleGroupbox(id) {
var elt = document.getElementById(id);
if (elt.hasAttribute("closed")) {
elt.removeAttribute("closed");
if (elt.flexWhenOpened)
elt.flex = elt.flexWhenOpened;
} else {
elt.setAttribute("closed", "true");
if (elt.flex) {
elt.flexWhenOpened = elt.flex;
elt.flex = 0;
}
}
}
function openCacheEntry(key, cb) {
var checkCacheListener = {
onCacheEntryCheck(entry, appCache) {
@ -523,20 +508,20 @@ function makeGeneralTab(metaViewRows, docInfo) {
var metaGroup = document.getElementById("metaTags");
if (!length)
metaGroup.collapsed = true;
metaGroup.style.visibility = "hidden";
else {
var metaTagsCaption = document.getElementById("metaTagsCaption");
if (length == 1)
metaTagsCaption.label = gBundle.getString("generalMetaTag");
metaTagsCaption.value = gBundle.getString("generalMetaTag");
else
metaTagsCaption.label = gBundle.getFormattedString("generalMetaTags", [length]);
metaTagsCaption.value = gBundle.getFormattedString("generalMetaTags", [length]);
var metaTree = document.getElementById("metatree");
metaTree.view = gMetaView;
// Add the metaViewRows onto the general tab's meta info tree.
gMetaView.addRows(metaViewRows);
metaGroup.collapsed = false;
metaGroup.style.removeProperty("visibility");
}
// get the date of last modification

View File

@ -142,8 +142,8 @@
</rows>
</grid>
<separator class="thin"/>
<groupbox id="metaTags" flex="1" class="collapsable treebox">
<caption id="metaTagsCaption" onclick="toggleGroupbox('metaTags');"/>
<vbox id="metaTags" flex="1">
<label control="metatree" id="metaTagsCaption" class="header"/>
<tree id="metatree" flex="1" hidecolumnpicker="true" contextmenu="picontext">
<treecols>
<treecol id="meta-name" label="&generalMetaName;"
@ -156,7 +156,7 @@
</treecols>
<treechildren id="metatreechildren" flex="1"/>
</tree>
</groupbox>
</vbox>
<hbox pack="end">
<button command="cmd_help" label="&helpButton.label;" dlgtype="help"/>
</hbox>

View File

@ -98,35 +98,6 @@ textbox[disabled] {
margin-inline-start: 5px;
}
groupbox.collapsable caption .caption-icon {
width: 9px;
height: 9px;
background-repeat: no-repeat;
background-position: center;
margin-inline-start: 1px;
margin-inline-end: 3px;
background-image: url("chrome://global/skin/tree/twisty-open.png");
}
groupbox.collapsable[closed="true"] {
border: none;
}
groupbox.collapsable[closed="true"] caption .caption-icon {
background-image: url("chrome://global/skin/tree/twisty-clsd.png");
}
groupbox tree {
margin: 0;
border: none;
}
groupbox.treebox .groupbox-body {
margin-inline-start: 5px;
margin-inline-end: 1px;
padding-top: 0;
}
#securityBox description {
margin-inline-start: 10px;
}

View File

@ -72,27 +72,6 @@ textbox[disabled] {
}
/* General Tab */
groupbox.collapsable caption .caption-icon {
width: 11px;
height: 11px;
background-repeat: no-repeat;
background-position: center;
margin-inline-end: 2px;
background-image: url("chrome://global/skin/arrow/arrow-dn.gif");
}
groupbox.collapsable[closed="true"] caption .caption-icon {
background-image: url("chrome://global/skin/arrow/arrow-rit.gif");
}
groupbox tree {
margin: 0;
border: none;
}
groupbox.treebox .groupbox-body {
padding: 0;
}
#securityBox description {
margin-inline-start: 10px;

View File

@ -122,30 +122,6 @@ textbox[disabled] {
}
/* General Tab */
groupbox.collapsable caption .caption-icon {
width: 9px;
height: 9px;
background-repeat: no-repeat;
background-position: center;
margin-inline-start: 2px;
margin-inline-end: 2px;
background-image: url("chrome://global/skin/tree/twisty.svg#open");
}
groupbox.collapsable[closed="true"] {
border: none;
margin-bottom: 9px;
-moz-appearance: none;
}
groupbox.collapsable[closed="true"] caption .caption-icon {
background-image: url("chrome://global/skin/tree/twisty.svg#clsd");
}
groupbox tree {
margin: 0 3px;
border: none;
}
#securityBox description {
margin-inline-start: 10px;

Binary file not shown.

Before

Width:  |  Height:  |  Size: 57 B

View File

@ -48,7 +48,6 @@ toolkit.jar:
skin/classic/global/arrow/arrow-lft-sharp.gif (arrow/arrow-lft-sharp.gif)
skin/classic/global/arrow/arrow-rit-dis.gif (arrow/arrow-rit-dis.gif)
skin/classic/global/arrow/arrow-rit-sharp.gif (arrow/arrow-rit-sharp.gif)
skin/classic/global/arrow/arrow-rit.gif (arrow/arrow-rit.gif)
skin/classic/global/arrow/arrow-up-dis.gif (arrow/arrow-up-dis.gif)
skin/classic/global/arrow/arrow-up-sharp.gif (arrow/arrow-up-sharp.gif)
skin/classic/global/arrow/arrow-up.gif (arrow/arrow-up.gif)