зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1388501 - Fixed missing PHA warning page on Fennec. r=francois
MozReview-Commit-ID: FPf85QAO2C9 --HG-- extra : rebase_source : 33fa0381479cc454deca8c6061ccd4ebb1e539b1
This commit is contained in:
Родитель
fa53d431d3
Коммит
f6ee4abf9c
|
@ -90,6 +90,9 @@
|
|||
case "unwantedBlocked" :
|
||||
error = "unwanted";
|
||||
break;
|
||||
case "harmfulBlocked" :
|
||||
error = "harmful";
|
||||
break;
|
||||
default:
|
||||
return;
|
||||
}
|
||||
|
@ -123,6 +126,13 @@
|
|||
el.remove();
|
||||
}
|
||||
|
||||
if (error !== "harmful") {
|
||||
el = document.getElementById("errorTitleText_harmful");
|
||||
el.remove();
|
||||
el = document.getElementById("errorShortDescText_harmful");
|
||||
el.remove();
|
||||
}
|
||||
|
||||
if (!getOverride()) {
|
||||
var btn = document.getElementById("ignoreWarningButton");
|
||||
if (btn) {
|
||||
|
@ -131,7 +141,11 @@
|
|||
}
|
||||
|
||||
// Set sitename
|
||||
document.getElementById(error + "_sitename").textContent = getHostString();
|
||||
let siteElem = document.getElementById(error + "_sitename");
|
||||
if (siteElem) {
|
||||
siteElem.textContent = getHostString();
|
||||
}
|
||||
|
||||
document.title = document.getElementById("errorTitleText_" + error)
|
||||
.innerHTML;
|
||||
|
||||
|
@ -151,15 +165,17 @@
|
|||
<h1 id="errorTitleText_phishing" class="errorTitleText">&safeb.blocked.phishingPage.title3;</h1>
|
||||
<h1 id="errorTitleText_malware" class="errorTitleText">&safeb.blocked.malwarePage.title;</h1>
|
||||
<h1 id="errorTitleText_unwanted" class="errorTitleText">&safeb.blocked.unwantedPage.title;</h1>
|
||||
<h1 id="errorTitleText_harmful" class="errorTitleText">&safeb.blocked.harmfulPage.title;</h1>
|
||||
</div>
|
||||
|
||||
<div id="errorLongContent">
|
||||
|
||||
|
||||
<!-- Short Description -->
|
||||
<div id="errorShortDesc">
|
||||
<p id="errorShortDescText_phishing">&safeb.blocked.phishingPage.shortDesc3;</p>
|
||||
<p id="errorShortDescText_malware">&safeb.blocked.malwarePage.shortDesc;</p>
|
||||
<p id="errorShortDescText_unwanted">&safeb.blocked.unwantedPage.shortDesc;</p>
|
||||
<p id="errorShortDescText_harmful">&safeb.blocked.harmfulPage.shortDesc;</p>
|
||||
</div>
|
||||
|
||||
<!-- Long Description -->
|
||||
|
|
|
@ -23,3 +23,5 @@
|
|||
<!ENTITY safeb.blocked.unwantedPage.shortDesc "This web page at <span id='unwanted_sitename'/> has been reported to contain unwanted software and has been blocked based on your security preferences.">
|
||||
<!ENTITY safeb.blocked.unwantedPage.longDesc "Unwanted software pages try to install software that can be deceptive and affect your system in unexpected ways.">
|
||||
|
||||
<!ENTITY safeb.blocked.harmfulPage.title "The site ahead may contain malware">
|
||||
<!ENTITY safeb.blocked.harmfulPage.shortDesc "&brandShortName; blocked this page because it might try to install dangerous apps that steal or delete your information (for example, photos, passwords, messages and credit cards).">
|
Загрузка…
Ссылка в новой задаче