Bug 463923 - show expanded technical details in expert mode (SSL error pages). r=johnath/gavin

This commit is contained in:
Przemyslaw Bialik 2008-12-09 14:03:27 +01:00
parent fbb126a539
commit 386dee36ac
2 changed files with 6 additions and 3 deletions

View File

@ -119,6 +119,7 @@
replaceWithHost(intro);
if (getCSSClass() == "expertBadCert") {
toggle('technicalContent');
toggle('expertContent');
}
@ -206,7 +207,7 @@
// If we set a link, meaning there's something helpful for
// the user here, expand the section by default
if (link.href)
if (link.href && getCSSClass() != "expertBadCert")
toggle("technicalContent");
}
@ -249,13 +250,13 @@
</div>
</div>
<!-- The following sections can be unhidden by default by setting the
"browser.xul.error_pages.expert_bad_cert" pref to true -->
<div id="technicalContent" collapsed="true">
<h2 onclick="toggle('technicalContent');" id="technicalContentHeading">&certerror.technical.heading;</h2>
<p id="technicalContentText"/>
</div>
<!-- This section can be unhidden by default by setting the
"browser.xul.error_pages.expert_bad_cert" pref to true -->
<div id="expertContent" collapsed="true">
<h2 onclick="toggle('expertContent');" id="expertContentHeading">&certerror.expert.heading;</h2>
<div>

View File

@ -35,7 +35,9 @@ function testBrokenCert() {
function testExpertPref() {
var expertDiv = gBrowser.contentWindow.document.getElementById("expertContent");
var technicalDiv = gBrowser.contentWindow.document.getElementById("technicalContent");
ok(!expertDiv.hasAttribute("collapsed"), "Expert content should not be collapsed with the expert mode pref set");
ok(!technicalDiv.hasAttribute("collapsed"), "Technical content should not be collapsed with the expert mode pref set");
// Clean up
gBrowser.removeCurrentTab();