mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
bug 427293: add a pref to unhide the buttons on the bad-cert error page by default for advanced users. r=johnath, ui-r=beltzner, sr=jst, a=beltzner
This commit is contained in:
parent
6f31226edd
commit
6aca124433
@ -445,6 +445,7 @@ pref("alerts.slideIncrementTime", 10);
|
||||
pref("alerts.totalOpenTime", 4000);
|
||||
|
||||
pref("browser.xul.error_pages.enabled", true);
|
||||
pref("browser.xul.error_pages.expert_bad_cert", false);
|
||||
|
||||
// We want to make sure mail URLs are handled externally...
|
||||
pref("network.protocol-handler.external.mailto", true); // for mail
|
||||
|
@ -3036,6 +3036,12 @@ nsDocShell::DisplayLoadError(nsresult aError, nsIURI *aURI,
|
||||
if (!messageStr.IsEmpty()) {
|
||||
if (errorClass == nsINSSErrorsService::ERROR_CLASS_BAD_CERT) {
|
||||
error.AssignLiteral("nssBadCert");
|
||||
PRBool expert = PR_FALSE;
|
||||
mPrefs->GetBoolPref("browser.xul.error_pages.expert_bad_cert",
|
||||
&expert);
|
||||
if (expert) {
|
||||
cssClass.AssignLiteral("expertBadCert");
|
||||
}
|
||||
} else {
|
||||
error.AssignLiteral("nssFailure2");
|
||||
}
|
||||
|
@ -163,9 +163,10 @@
|
||||
errContainer.parentNode.removeChild(errContainer);
|
||||
|
||||
var className = getCSSClass();
|
||||
if (className) {
|
||||
if (className && className != "expertBadCert") {
|
||||
// Associate a CSS class with the root of the page, if one was passed in,
|
||||
// to allow custom styling.
|
||||
// Not "expertBadCert" though, don't want to deal with the favicon
|
||||
document.documentElement.className = className;
|
||||
|
||||
// Also, if they specified a CSS class, they must supply their own
|
||||
@ -177,6 +178,9 @@
|
||||
favicon.setAttribute("href", "chrome://global/skin/icons/" + className + "_favicon.png");
|
||||
faviconParent.appendChild(favicon);
|
||||
}
|
||||
if (className == "expertBadCert") {
|
||||
showSecuritySection();
|
||||
}
|
||||
|
||||
if (err == "nssBadCert") {
|
||||
// Remove the "Try again" button for security exceptions, since it's
|
||||
|
Loading…
Reference in New Issue
Block a user