Bug 546857 Part 4b: Fix some errors in previous patch to not use XUL on error pages. r=dao a=blocker

This commit is contained in:
Jonas Sicking 2010-08-21 18:49:27 +02:00
parent 1fb16b80d7
commit 7d4a71f96d
5 changed files with 14 additions and 14 deletions

View File

@ -2604,11 +2604,6 @@ function BrowserOnClick(event) {
);
}
}
else if (/^about:privatebrowsing/.test(errorDoc.documentURI)) {
if (ot == errorDoc.getElementById("startPrivateBrowsing")) {
gPrivateBrowsingUI.toggleMode();
}
}
}
/**

View File

@ -114,6 +114,10 @@
if (moreInfoLink)
moreInfoLink.setAttribute("href", moreInfoURL + "private-browsing");
}, false);
function togglePrivateBrowsing() {
mainWindow.gPrivateBrowsingUI.toggleMode();
}
]]></script>
</head>
@ -145,9 +149,10 @@
<!-- Start Private Browsing -->
<div id="startPrivateBrowsingDesc" class="showNormal">
<button id="startPrivateBrowsing"
<button xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"
id="startPrivateBrowsing" label="&privatebrowsingpage.startPrivateBrowsing.label;"
accesskey="&privatebrowsingpage.startPrivateBrowsing.accesskey;"
>&privatebrowsingpage.startPrivateBrowsing.label;</button>
oncommand="togglePrivateBrowsing();"/>
</div>
<!-- Footer -->

View File

@ -170,12 +170,12 @@ be temporary, and you can try again later.</li>
<!ENTITY securityOverride.getMeOutOfHereButton "Get me out of here!">
<!ENTITY securityOverride.exceptionButtonLabel "Add Exception…">
<!-- LOCALIZATION NOTE (securityOverride.warningText) - Do not translate the
contents of the <xul:button> tags. The only language content is the label= field,
which uses strings already defined above. The button is included here (instead of
netError.xhtml) because it exposes functionality specific to firefox. -->
<!-- LOCALIZATION NOTE (securityOverride.warningContent) - Do not translate the
contents of the <button> tags. It uses strings already defined above. The
button is included here (instead of netError.xhtml) because it exposes
functionality specific to firefox. -->
<!ENTITY securityOverride.warningText "
<!ENTITY securityOverride.warningContent "
<p>You should not add an exception if you are using an internet connection that you do not trust completely or if you are not used to seeing a warning for this server.</p>
<button id='getMeOutOfHereButton'>&securityOverride.getMeOutOfHereButton;</button>

View File

@ -369,7 +369,7 @@
error types. -->
<div id="securityOverrideDiv">
<a id="securityOverrideLink" href="javascript:showSecuritySection();" >&securityOverride.linkText;</a>
<div id="securityOverrideContent" style="display: none;">&securityOverride.warningText;</div>
<div id="securityOverrideContent" style="display: none;">&securityOverride.warningContent;</div>
</div>
</div>

View File

@ -3,7 +3,7 @@
should go into netError.dtd -->
<!ENTITY securityOverride.linkText "Or you can add an exception…">
<!ENTITY securityOverride.warningText "
<!ENTITY securityOverride.warningContent "
<p>You should not add an exception if you are using an internet connection that you do not trust completely or if you are not used to seeing a warning for this server.</p>
<p>If you still wish to add an exception for this site, you can do so in your advanced encryption settings.</p>
">