зеркало из https://github.com/mozilla/gecko-dev.git
Bug 333860 - When starting offline, Compatibility Wizard should not be checking for updates. patch=Dave Townsend (Mossop), r=rob_strong, ui-r=beltzner
This commit is contained in:
Родитель
0a07420a3d
Коммит
8bbe04e7d8
|
@ -1,5 +1,12 @@
|
|||
<!ENTITY updateWizard.title "&brandShortName; Update">
|
||||
|
||||
<!ENTITY offline.title "&brandShortName; is working offline">
|
||||
<!ENTITY offline.description "&brandShortName; needs to go online in order to see if updates
|
||||
are available for your add-ons to make them compatible with this
|
||||
version.">
|
||||
<!ENTITY offline.toggleOffline.label "Go online now.">
|
||||
<!ENTITY offline.toggleOffline.accesskey "G">
|
||||
|
||||
<!ENTITY mismatch.win.title "Incompatible Add-ons">
|
||||
<!ENTITY mismatch.introduction1.label "The following add-ons are not compatible with this version
|
||||
of &brandShortName;:">
|
||||
|
|
|
@ -89,8 +89,14 @@ var gUpdateWizard = {
|
|||
}
|
||||
catch (e) {
|
||||
}
|
||||
document.documentElement.currentPage =
|
||||
document.getElementById("versioninfo");
|
||||
var ioService = Components.classes["@mozilla.org/network/io-service;1"]
|
||||
.getService(Components.interfaces.nsIIOService);
|
||||
if (ioService.offline)
|
||||
document.documentElement.currentPage =
|
||||
document.getElementById("offline");
|
||||
else
|
||||
document.documentElement.currentPage =
|
||||
document.getElementById("versioninfo");
|
||||
},
|
||||
|
||||
onWizardFinish: function ()
|
||||
|
@ -161,6 +167,22 @@ var gUpdateWizard = {
|
|||
}
|
||||
};
|
||||
|
||||
var gOfflinePage = {
|
||||
onPageAdvanced: function ()
|
||||
{
|
||||
var ioService = Components.classes["@mozilla.org/network/io-service;1"]
|
||||
.getService(Components.interfaces.nsIIOService);
|
||||
ioService.offline = false;
|
||||
return true;
|
||||
},
|
||||
|
||||
toggleOffline: function ()
|
||||
{
|
||||
var nextbtn = document.documentElement.getButton("next");
|
||||
nextbtn.disabled = !nextbtn.disabled;
|
||||
}
|
||||
}
|
||||
|
||||
var gVersionInfoPage = {
|
||||
_completeCount: 0,
|
||||
_totalCount: 0,
|
||||
|
|
|
@ -67,6 +67,17 @@
|
|||
|
||||
<wizardpage id="dummy" pageid="dummy"/>
|
||||
|
||||
<wizardpage id="offline" pageid="offline" next="versioninfo"
|
||||
label="&offline.title;"
|
||||
onpageadvanced="return gOfflinePage.onPageAdvanced();">
|
||||
<description>&offline.description;</description>
|
||||
<checkbox id="toggleOffline"
|
||||
checked="true"
|
||||
label="&offline.toggleOffline.label;"
|
||||
accesskey="&offline.toggleOffline.accesskey;"
|
||||
oncommand="gOfflinePage.toggleOffline();"/>
|
||||
</wizardpage>
|
||||
|
||||
<wizardpage id="versioninfo" pageid="versioninfo" next="mismatch"
|
||||
label="&compatCheck.title;"
|
||||
onpageshow="gVersionInfoPage.onPageShow();">
|
||||
|
|
Загрузка…
Ссылка в новой задаче