Bug 490097 - "Clean up autoconfig strings and move them from content to locales" [r=bienvenu,ui-review=clarkbw]

--HG--
rename : mail/base/content/accountCreation.dtd => mail/locales/en-US/chrome/messenger/accountCreation.dtd
rename : mail/base/content/accountCreation.properties => mail/locales/en-US/chrome/messenger/accountCreation.properties
rename : mail/base/content/accountCreationModel.properties => mail/locales/en-US/chrome/messenger/accountCreationModel.properties
rename : mail/base/content/accountCreationUtil.properties => mail/locales/en-US/chrome/messenger/accountCreationUtil.properties
This commit is contained in:
Blake Winton 2009-08-04 17:49:22 +01:00
Родитель c4a940a828
Коммит 5628a6088b
14 изменённых файлов: 132 добавлений и 300 удалений

Просмотреть файл

@ -10,10 +10,6 @@ messenger.jar:
% style chrome://global/content/customizeToolbar.xul chrome://messenger/skin/messengercompose/messengercompose.css
% style chrome://global/content/customizeToolbar.xul chrome://messenger/skin/smime/msgCompSMIMEOverlay.css
% style chrome://global/content/customizeToolbar.xul chrome://messenger/skin/primaryToolbar.css
content/messenger/accountCreation.dtd (content/accountCreation.dtd)
content/messenger/accountCreation.properties (content/accountCreation.properties)
content/messenger/accountCreationModel.properties (content/accountCreationModel.properties)
content/messenger/accountCreationUtil.properties (content/accountCreationUtil.properties)
content/messenger/mailWindow.js (content/mailWindow.js)
content/messenger/messageDisplay.js (content/messageDisplay.js)
content/messenger/folderDisplay.js (content/folderDisplay.js)

Просмотреть файл

@ -5,68 +5,70 @@
<!ENTITY password.description "Password">
<!ENTITY next.label "Next &#187;">
<!ENTITY next.accesskey "N">
<!ENTITY back.label "&#171; Back">
<!ENTITY back.accesskey "B">
<!ENTITY accountInformation.label "Account Information">
<!ENTITY username.label "username">
<!ENTITY receivingserver.label "receiving">
<!ENTITY sendingserver.label "sending">
<!ENTITY noencryption.label "None">
<!ENTITY receivingServer.label "receiving">
<!ENTITY sendingServer.label "sending">
<!ENTITY noEncryption.label "None">
<!ENTITY starttls.label "STARTTLS">
<!ENTITY ssltls2.label "SSL/TLS">
<!ENTITY sslTls.label "SSL/TLS">
<!ENTITY imap.label "IMAP">
<!ENTITY pop.label "POP">
<!ENTITY smtp.label "SMTP">
<!-- LOCALIZATION NOTE (gotoadvanced2.label): This label is a link which
will create the account and take the user to the account configuration
screen. -->
<!ENTITY gotoadvanced2.label "Create in Advanced Editor">
<!-- LOCALIZATION NOTE (createAndEditSettings.label): This label is a link
which will create the account and take the user to the account
configuration screen. -->
<!ENTITY createAndEditSettings.label "Create and Edit Account Settings">
<!ENTITY cancel.label "Cancel">
<!ENTITY stop.label "Stop">
<!ENTITY stop.accesskey "S">
<!-- LOCALIZATION NOTE (retest.label): This is the text that is
displayed on the button which will re-guess the account configuration,
taking into account the settings the user has changed.
-->
taking into account the settings the user has changed. -->
<!ENTITY retest.label "Re-test Configuration">
<!ENTITY retest.accesskey "R">
<!ENTITY edit.label "Edit">
<!ENTITY createaccount.label "Create Account">
<!ENTITY edit.accesskey "E">
<!ENTITY rememberpassword.label "Remember password">
<!ENTITY rememberPassword.label "Remember password">
<!ENTITY rememberPassword.accesskey "m">
<!ENTITY warning.label "Warning!">
<!ENTITY incoming_settings.label "Incoming settings:">
<!ENTITY outgoing_settings.label "Outgoing settings:">
<!ENTITY technicaldetails.label "Technical Details">
<!-- LOCALIZATION NOTE (incoming_is_checked2.label): If there is a security
<!ENTITY incomingSettings.label "Incoming settings:">
<!ENTITY outgoingSettings.label "Outgoing settings:">
<!-- LOCALIZATION NOTE (confirmIncomingWarning.label): If there is a security
warning on the incoming server, then the user will need to check a
checkbox beside this text before continuing. -->
<!ENTITY incoming_is_checked2.label "I understand the risks.">
<!-- LOCALIZATION NOTE (outgoing_is_checked2.label): If there is a security
<!ENTITY confirmIncomingWarning.label "I understand the risks.">
<!ENTITY confirmIncomingWarning.accesskey "u">
<!-- LOCALIZATION NOTE (confirmOutgoingWarning.label): If there is a security
warning on the outgoing server, then the user will need to check a
checkbox beside this text before continuing. -->
<!ENTITY outgoing_is_checked2.label "I understand the risks.">
<!-- LOCALIZATION NOTE (understood2.label): If there is a security warning
<!ENTITY confirmOutgoingWarning.label "I understand the risks.">
<!ENTITY confirmOutgoingWarning.accesskey "d">
<!-- LOCALIZATION NOTE (createAccount.label): If there is a security warning
on the incoming or outgoing servers, then the page that pops up will
have this text in a button to continue by creating the account. -->
<!ENTITY understood2.label "Create Account">
<!-- LOCALIZATION NOTE (getmeout2.label): If there is a security warning on
<!ENTITY createAccount.label "Create Account">
<!ENTITY createAccount.accesskey "C">
<!-- LOCALIZATION NOTE (changeSettings.label): If there is a security warning on
the incoming or outgoing servers, then the page that pops up will have
this text in a button to take you back to the previous page. -->
<!ENTITY getmeout2.label "Get me out of here!">
this text in a button to take you back to the previous page to change
the settings and try again. -->
<!ENTITY changeSettings.label "Change Settings">
<!ENTITY changeSettings.accesskey "S">
<!ENTITY lectureYourProvider2.description "&brandShortName; can allow you to get to your mail using the provided configurations. However, you should contact your administrator or email provider regarding these improper connections. See the Thunderbird FAQ for more information.">
<!ENTITY contactYourProvider.description "&brandShortName; can allow you to get to your mail using the provided configurations. However, you should contact your administrator or email provider regarding these improper connections. See the Thunderbird FAQ for more information.">
<!ENTITY insecureServer.tooltip.title "Warning! This is an insecure server.">
<!ENTITY insecureServer.tooltip.details "Click circle for more details.">
<!ENTITY insecureCleartext.description "Email is sent in clear-text, so your email could be read by attackers, etc. &brandShortName; will let you get to your mail, but you should really get your email provider to configure the server with a secure connection.">
<!ENTITY insecureSelfsigned.description "The server uses a certificate that we can't trust, so we can't be sure that someone isn't intercepting the traffic between &brandShortName; and your server. &brandShortName; will let you get to your mail, but you should really get your email provider to configure the server with a trusted certificate.">
<!ENTITY insecureClearText.description "Email is sent in clear-text, so your email could be read by attackers, etc. &brandShortName; will let you get to your mail, but you should really get your email provider to configure the server with a secure connection.">
<!ENTITY insecureSelfSigned.description "The server uses a certificate that we can't trust, so we can't be sure that someone isn't intercepting the traffic between &brandShortName; and your server. &brandShortName; will let you get to your mail, but you should really get your email provider to configure the server with a trusted certificate.">
<!ENTITY secureServer.description "Congratulations! This is a secure server.">
<!ENTITY customfields-header.label "Additional information">
<!ENTITY customfields-intro1.descr "For your mail provider, there is additional information needed to configure your account.">
<!ENTITY customfields-intro2.descr "Please look up the information in the paper or email with your account details that the provider sent you, usually when you signed up there, and enter it below.">
<!ENTITY customfields-cancel.label "Back">
<!ENTITY customfields-ok.label "OK">

Просмотреть файл

@ -1,21 +1,21 @@
# accountCreation.properties
# LOCALIZATION NOTE: %1$S will be the name of the app (i.e. ThunderBird), %2$S will be the hostname of the server the user was trying to connect to.
cleartext_incoming2=You've setup %1$S to connect to the incoming mail server %2$S, which is an insecure server.
selfsigned_incoming2=You've setup %1$S to connect securely to the incoming mail server %2$S, but we can't confirm that your connection is secure.
cleartext_outgoing2=You've setup %1$S to connect to the outgoing mail server %2$S, which is an insecure server.
selfsigned_outgoing2=You've setup %1$S to connect securely to the outgoing mail server %2$S, but we can't confirm that your connection is secure.
incoming_cleartext_warning=You've setup %1$S to connect to the incoming mail server %2$S, which is an insecure server.
incoming_selfsigned_warning=You've setup %1$S to connect securely to the incoming mail server %2$S, but we can't confirm that your connection is secure.
outgoing_cleartext_warning=You've setup %1$S to connect to the outgoing mail server %2$S, which is an insecure server.
outgoing_selfsigned_warning=You've setup %1$S to connect securely to the outgoing mail server %2$S, but we can't confirm that your connection is secure.
selfsigned_details=Normally, a secure mail server will present a trusted certificate to prove that it is really the server it claims to be. The connection to the mail server will be encrypted but cannot be validated as being the correct server.
cleartext_details=Insecure mail servers do not use encrypted connections to protect your passwords and private information. By connecting to this server you could expose your password and private information.
# LOCALIZATION NOTE(defaultServerTag): Used to indicate the default smtp server in the server dropdown list.
defaultServerTag= (default)
# LOCALIZATION NOTE(default_server_tag): Used to indicate the default smtp server in the server dropdown list.
default_server_tag= (default)
# config titles
searching_for_configs=Searching…
manually_edit_config=Editing Config
finished_with_success=Finished
finished_with_errors2=Error
finished_with_error=Error
# config subtitles
check_preconfig=checking for pre-configuration…
@ -27,10 +27,10 @@ found_isp_config=found a configuration
probing_config=probing configuration…
guessing_from_email=guessing configuration…
config_details_found=Your configuration details have been found!
config_not_verified2=Configuration could not be verified — is the username or password wrong?
config_unverifiable=Configuration could not be verified — is the username or password wrong?
incoming_found_specify_outgoing=Your incoming server configuration details have been found, please specify the sending hostname.
outgoing_found_specify_incoming=Your outgoing server configuration details have been found, please specify the receiving hostname.
enter_missing_hostnames2=Could not guess settings — please enter missing hostnames
please_enter_missing_hostnames=Could not guess settings — please enter missing hostnames.
incoming_failed_trying_outgoing=Could not automatically configure incoming server, still trying for outgoing server.
outgoing_failed_trying_incoming=Could not automatically configure outgoing server, still trying for incoming server.
checking_password=Checking password…
@ -44,13 +44,9 @@ error_creating_account=Error Creating Account
incoming_server_exists=Incoming server already exists.
no_encryption=No encryption
ssltls2=SSL/TLS
ssl_tls=SSL/TLS
starttls=STARTTLS
name.error=Please enter your name, as it should be shown to your correspondents.
email.error=Double check this email address!
password.error=Login did not succeed. Please double-check username and password.
customfields_example.label=Example:
customfields_empty.error=You need to fill out these fields, with the information given to you by your provider
customfields_tooMany.error=Too many input fields in config XML file

Просмотреть файл

@ -5,7 +5,7 @@
# sanitizeDatatypes.js
hostname_syntax.error=Hostname is empty or contains forbidden characters. Only letters, numbers, - and . are allowed.
alphanumdash.error=String contains unsupported characters. Only letters, numbers, - and _ are allowed.
enum_value2.error=Supplied value not in allowed list
allowed_value.error=Supplied value not in allowed list
url_scheme.error=URL scheme not allowed
url_parsing.error=URL not recognized
string_empty.error=You must supply a value for this string

Просмотреть файл

@ -9,6 +9,10 @@
locale/@AB_CD@/messenger/aboutDialog.dtd (%chrome/messenger/aboutDialog.dtd)
locale/@AB_CD@/messenger/aboutRights.dtd (%chrome/messenger/aboutRights.dtd)
locale/@AB_CD@/messenger/aboutRights.properties (%chrome/messenger/aboutRights.properties)
locale/@AB_CD@/messenger/accountCreation.dtd (%chrome/messenger/accountCreation.dtd)
locale/@AB_CD@/messenger/accountCreation.properties (%chrome/messenger/accountCreation.properties)
locale/@AB_CD@/messenger/accountCreationModel.properties (%chrome/messenger/accountCreationModel.properties)
locale/@AB_CD@/messenger/accountCreationUtil.properties (%chrome/messenger/accountCreationUtil.properties)
locale/@AB_CD@/messenger/systemIntegrationDialog.dtd (%chrome/messenger/systemIntegrationDialog.dtd)
locale/@AB_CD@/messenger/virtualFolderProperties.dtd (%chrome/messenger/virtualFolderProperties.dtd)
locale/@AB_CD@/messenger/virtualFolderListDialog.dtd (%chrome/messenger/virtualFolderListDialog.dtd)

Просмотреть файл

@ -165,15 +165,8 @@ AccountConfig.kSourceGuess = 3; // guessConfig()
*
* @param password {String}
* The password for the incoming server and (if necessary) the outgoing server
*
* @param otherVariables {Object}
* Associative array of variable name
* (without %) and value, e.g. var name "username" with value "fred"
* would be passed as JS object { username: "fred" } .
* The var names must exactly match account.inputFields (all vars supplied,
* no other vars). If account.inputFields is empty or null, pass {} .
*/
function replaceVariables(account, realname, emailfull, password, otherVariables)
function replaceVariables(account, realname, emailfull, password)
{
sanitize.nonemptystring(emailfull);
let emailsplit = emailfull.split("@");
@ -184,6 +177,7 @@ function replaceVariables(account, realname, emailfull, password, otherVariables
sanitize.label(realname);
sanitize.nonemptystring(realname);
let otherVariables = {};
otherVariables.EMAILADDRESS = emailfull;
otherVariables.EMAILLOCALPART = emaillocal;
otherVariables.EMAILDOMAIN = emaildomain;

Просмотреть файл

@ -125,7 +125,6 @@ EmailConfigWizard.prototype =
this._incomingWarning = 'cleartext';
this._outgoingWarning = 'cleartext';
this._userPickedOutgoingServer = false;
this._customFields = {}; // map of: field ID from config file {String} -> field value entered by user {String}
if (window.arguments && window.arguments[0] &&
window.arguments[0].msgWindow)
@ -146,7 +145,7 @@ EmailConfigWizard.prototype =
var menuitem = document.createElement("menuitem");
var label = server.displayname;
if (server.key == gSmtpManager.defaultServer.key)
label += " " + gStringsBundle.getString("defaultServerTag");
label += " " + gStringsBundle.getString("default_server_tag");
menuitem.setAttribute("label", label);
menuitem.setAttribute("value", server.key);
@ -451,8 +450,8 @@ EmailConfigWizard.prototype =
{
gEmailWizardLogger.info("guessConfig failed: " + e);
me.updateConfig(config);
me.stopSpinner("finished_with_errors2");
me.setSpinnerStatus("enter_missing_hostnames2");
me.stopSpinner("finished_with_error");
me.setSpinnerStatus("please_enter_missing_hostnames");
me._probeAbortable = null;
me.editConfigDetails();
},
@ -497,7 +496,7 @@ EmailConfigWizard.prototype =
this._currentConfigFilledIn = config.copy();
_show("advanced_settings");
replaceVariables(this._currentConfigFilledIn, this._realname, this._email,
this._password, this._customFields);
this._password);
this.updateConfig(this._currentConfigFilledIn);
@ -586,31 +585,31 @@ EmailConfigWizard.prototype =
let incoming_details;
let outgoing_details;
let incoming = this._currentConfigFilledIn.incoming;
let incoming_settings = incoming.hostname + ':' + incoming.port +
let incomingSettings = incoming.hostname + ':' + incoming.port +
' (' + sslLabel(incoming.socketType) + ')';
let outgoing = this._currentConfigFilledIn.outgoing;
let outgoing_settings = outgoing.hostname + ':' + outgoing.port +
let outgoingSettings = outgoing.hostname + ':' + outgoing.port +
' (' + sslLabel(outgoing.socketType) + ')';
var brandShortName = gBrandBundle.getString("brandShortName");
switch (this._incomingWarning)
{
case 'cleartext':
incomingwarningstring = gStringsBundle.getFormattedString(
"cleartext_incoming2", [brandShortName, incoming.hostname]);
"incoming_cleartext_warning", [brandShortName, incoming.hostname]);
incoming_details = gStringsBundle.getString("cleartext_details");
setText('warning_incoming', incomingwarningstring);
setText('incoming_details', incoming_details);
setText('incoming_settings', incoming_settings);
setText('incomingSettings', incomingSettings);
_show('incoming_box');
_show('acknowledge_incoming');
break;
case 'selfsigned':
incomingwarningstring = gStringsBundle.getFormattedString(
"selfsigned_incoming2", [brandShortName, incoming.hostname]);
"incoming_selfsigned_warning", [brandShortName, incoming.hostname]);
incoming_details = gStringsBundle.getString("selfsigned_details");
setText('warning_incoming', incomingwarningstring);
setText('incoming_details', incoming_details);
setText('incoming_settings', incoming_settings);
setText('incomingSettings', incomingSettings);
_show('incoming_box');
_show('acknowledge_incoming');
break;
@ -622,21 +621,21 @@ EmailConfigWizard.prototype =
{
case 'cleartext':
outgoingwarningstring = gStringsBundle.getFormattedString(
"cleartext_outgoing2", [brandShortName, outgoing.hostname]);
outgoingdetailsstring = gStringsBundle.getString("cleartext_details");
"outgoing_cleartext_warning", [brandShortName, outgoing.hostname]);
outgoing_details = gStringsBundle.getString("cleartext_details");
setText('warning_outgoing', outgoingwarningstring);
setText('outgoing_details', outgoing_details);
setText('outgoing_settings', outgoing_settings);
setText('outgoingSettings', outgoingSettings);
_show('outgoing_box');
_show('acknowledge_outgoing');
break;
case 'selfsigned':
outgoingwarningstring = gStringsBundle.getFormattedString(
"selfsigned_outgoing2", [brandShortName, outgoing.hostname]);
"outgoing_selfsigned_warning", [brandShortName, outgoing.hostname]);
outgoing_details = gStringsBundle.getString("selfsigned_details");
setText('warning_outgoing', outgoingwarningstring);
setText('outgoing_details', outgoing_details);
setText('outgoing_settings', outgoing_settings);
setText('outgoingSettings', outgoingSettings);
_show('outgoing_box');
_show('acknowledge_outgoing');
break;
@ -719,10 +718,10 @@ EmailConfigWizard.prototype =
},
function(e) // failed
{
me.stopSpinner("config_not_verified2");
me.stopSpinner("config_unverifiable");
me.setError('passworderror', 'user_pass_invalid');
alertPrompt(gStringsBundle.getString("error_creating_account"),
gStringsBundle.getString("config_not_verified2"));
gStringsBundle.getString("config_unverifiable"));
if (errorCallback)
errorCallback(e);
});
@ -743,7 +742,7 @@ EmailConfigWizard.prototype =
: this.getUserConfig();
// call this to set the password
replaceVariables(config, this._realname, this._email,
this._password, this._customFields);
this._password);
gEmailWizardLogger.info("creating account in backend");
config.rememberPassword =
@ -1059,7 +1058,7 @@ EmailConfigWizard.prototype =
this._setOutgoingStatus('strong');
break;
case 1: // plain
this._setOutgoingStatus('weak');
this._setOutgoingStatus('weak', 'cleartext');
break;
default:
throw new NotReached("sslType " + config.incoming.socketType + " unknown");
@ -1278,12 +1277,22 @@ EmailConfigWizard.prototype =
}
},
onKeyDown : function (key)
onKeyDown : function (event)
{
if (key == 27)
let key = event.keyCode;
if (key == 27) {
this.onCancel();
else if (key == 13 && !getElementById('create_button').disabled)
return true;
}
if (key == 13 && !getElementById('create_button').hidden) {
this.onOK();
return true;
}
if (key == 13 && !getElementById('next_button').hidden) {
this.onNext();
return true;
}
return false;
},
onWizardShutdown: function EmailConfigWizard_onWizardshutdown() {
@ -1304,7 +1313,7 @@ function sslLabel(val)
case 1:
return gStringsBundle.getString("no_encryption");
case 2:
return gStringsBundle.getString("ssltls2");
return gStringsBundle.getString("ssl_tls");
case 3:
return gStringsBundle.getString("starttls");;
default:
@ -1326,154 +1335,3 @@ function setText(id, value)
else
throw new NotReached("XUL element type not supported");
}
/**
* Called by dialog logic, if there are custom fields needed
* The dialog just shows all these descriptions, and a textfield next to each,
* and returns the values the user entered.
*
* @param inputFields {Array} @see AccountConfig.inputFields
* @param defaults {Object}
* Associative array / map of
* field ID (from config file) -> default value in text field
* The default values can come from a previous invokation of the dialog.
* May be null.
*/
function CustomFieldsDialog(inputFields, defaults)
{
if (!defaults)
defaults = {};
this._inputFields = inputFields;
this._defaults = defaults;
}
CustomFieldsDialog.prototype =
{
/**
* Open dialog, unless the needed data is already in |defaults|.
* @param successCallback, cancelCallback @see open()
*/
openIfNeeded : function(successCallback, cancelCallback)
{
var needInput = false;
for (var i = 0; i < this._inputFields.length; i++)
{
let fieldid = this._inputFields[i].varname;
if (!this._defaults[fieldid])
needInput = true;
}
if (!needInput)
{
successCallback(this._defaults);
return;
}
this.open(successCallback, cancelCallback);
},
/**
* @param successCallback {Function({Object})}
* Will be called when the user entered all values and clicked OK.
* The first parameter contains the values that the user entered,
* in form Map of: field ID -> user value
*
* @param cancelCallback {Function()}
* The user cancelled the dialog.
*/
open : function(successCallback, cancelCallback)
{
this._successCallback = successCallback;
this._cancelCallback = cancelCallback;
var rows = getElementById("customfields-rows");
// first, clear dialog from any possible previous use
while (rows.hasChildNodes())
rows.removeChild(rows.firstChild);
for (var i = 0; i < this._inputFields.length; i++)
{
let fieldid = this._inputFields[i].varname;
let displayName = this._inputFields[i].displayName;
let exampleValue = this._inputFields[i].exampleValue;
// only 5 fields allowed per spec, to cut down on dialog size and preserve sanity
if (i >= 5)
throw new Exception(gStringsBundle.getString("customfields_tooMany.error"));
// Create UI widgets
let row = document.createElement("row");
let descr = document.createElement("description");
let textfield = document.createElement("textbox");
let exHBox = document.createElement("hbox");
let exLabel = document.createElement("label");
let example = document.createElement("label");
exHBox.appendChild(exLabel);
exHBox.appendChild(example);
row.appendChild(descr);
row.appendChild(textfield);
row.appendChild(exHBox);
rows.appendChild(row);
descr.setAttribute("class", "customfield-label");
textfield.setAttribute("class", "customfield-value");
example.setAttribute("class", "customfield-example");
// fieldid was already sanitized in readFrom XML.js as alphanumdash and uppercase
textfield.id = "customfield-value-" + fieldid;
exLabel.setAttribute("value", gStringsBundle.getString("customfields_example.label"));
// Set labels and values
descr.textContent = displayName;
example.setAttribute("value", exampleValue);
if (this._defaults && this._defaults[fieldid])
textfield.setAttribute("value", this._defaults[fieldid]);
}
_hide("mastervbox");
_show("customfields-box");
},
// UI button pressed
onCancel : function()
{
_show("mastervbox");
_hide("customfields-box");
gCustomFieldsDialog = null;
try {
this._cancelCallback();
} catch (e) {
// XXX TODO FIXME
alert(e.message); throw e;
}
},
// UI button pressed
onOK : function()
{
try {
var result = {};
for (var i = 0; i < this._inputFields.length; i++)
{
let fieldid = this._inputFields[i].varname;
result[fieldid] = getElementById("customfield-value-" + fieldid).value;
gEmailWizardLogger.info("User value for " + fieldid + " is " + result[fieldid]);
if (!result[fieldid])
{
getElementById("customfields-error").textContent =
gStringsBundle.getString("customfields_empty.error");
return;
}
}
_show("mastervbox");
_hide("customfields-box");
gCustomFieldsDialog = null;
this._successCallback(result);
} catch (e) { alert(e.message); throw e; } // TODO alertPrompt()
}
}
var gCustomFieldsDialog = null;

Просмотреть файл

@ -41,7 +41,7 @@
<!DOCTYPE window [
<!ENTITY % brandDTD SYSTEM "chrome://branding/locale/brand.dtd">
%brandDTD;
<!ENTITY % acDTD SYSTEM "chrome://messenger/content/accountCreation.dtd">
<!ENTITY % acDTD SYSTEM "chrome://messenger/locale/accountCreation.dtd">
%acDTD;
]>
@ -51,15 +51,15 @@
title="&welcome.description;"
style="&autoconfigWizard.style;"
onload="gEmailConfigWizard.onLoad();"
onkeydown="gEmailConfigWizard.onKeyDown()"
onkeypress="gEmailConfigWizard.onKeyDown(event)"
onclose="gEmailConfigWizard.onWizardShutdown();"
onunload="gEmailConfigWizard.onWizardShutdown();"
>
<stringbundleset>
<stringbundle id="bundle_brand" src="chrome://branding/locale/brand.properties"/>
<stringbundle id="strings" src="chrome://messenger/content/accountCreation.properties"/>
<stringbundle id="utilstrings" src="chrome://messenger/content/accountCreationUtil.properties"/>
<stringbundle id="strings" src="chrome://messenger/locale/accountCreation.properties"/>
<stringbundle id="utilstrings" src="chrome://messenger/locale/accountCreationUtil.properties"/>
</stringbundleset>
<script type="application/javascript"
src="chrome://messenger/content/accountcreation/util.js"/>
@ -93,7 +93,7 @@
<image class="insecureLarry"/>
<vbox flex="1">
<description class="title">&insecureServer.tooltip.title;</description>
<description class="details">&insecureCleartext.description;</description>
<description class="details">&insecureClearText.description;</description>
</vbox>
</hbox>
</panel>
@ -102,7 +102,7 @@
<image class="insecureLarry"/>
<vbox flex="1">
<description class="title">&insecureServer.tooltip.title;</description>
<description class="details">&insecureSelfsigned.description;</description>
<description class="details">&insecureSelfSigned.description;</description>
</vbox>
</hbox>
</panel>
@ -196,16 +196,20 @@
onblur="gEmailConfigWizard.onblurPassword();"/>
</row>
<row align="center">
<checkbox id="remember_password" label="&rememberpassword.label;" checked="true"/>
<checkbox id="remember_password"
accesskey="&rememberPassword.accesskey;"
label="&rememberPassword.label;" checked="true"/>
</row>
<row>
<hbox pack="end">
<button id="next_button"
hidden="true"
oncommand="gEmailConfigWizard.onNext();"
accesskey="&next.accesskey;"
label="&next.label;" class="larger-button"/>
<button id="back_button" class="smaller-button"
oncommand="gEmailConfigWizard.onBack();"
accesskey="&back.accesskey;"
label="&back.label;" hidden="true"/>
</hbox>
</row>
@ -222,13 +226,16 @@
<hbox pack="end">
<button id="stop_button"
oncommand="gEmailConfigWizard.onStop();"
accesskey="&stop.accesskey;"
label="&stop.label;" class="smaller-button"/>
<button id="edit_button"
oncommand="gEmailConfigWizard.onEdit();"
accesskey="&edit.accesskey;"
label="&edit.label;" class="smaller-button"
hidden="true"/>
<button id="go_button"
oncommand="gEmailConfigWizard.onGo();"
accesskey="&retest.accesskey;"
label="&retest.label;" class="smaller-button"
hidden="true"/>
</hbox>
@ -258,7 +265,7 @@
</hbox>
</vbox>
<vbox id="incomingarea">
<label class="textbox-label" value="&receivingserver.label;"
<label class="textbox-label" value="&receivingServer.label;"
control="incoming_server"/>
<hbox>
<vbox id="incoming_status" class="icon" width="22"/>
@ -295,16 +302,16 @@
disabled="true"
class="security">
<menupopup onpopuphidden="gEmailConfigWizard.setSecurity('incoming_security')">
<menuitem label="&noencryption.label;" value="1"/>
<menuitem label="&noEncryption.label;" value="1"/>
<menuitem label="&starttls.label;" value="3"/>
<menuitem label="&ssltls2.label;" value="2"/>
<menuitem label="&sslTls.label;" value="2"/>
</menupopup>
</menulist>
</hbox>
</hbox>
</vbox>
<vbox id="outgoingarea">
<label class="textbox-label" value="&sendingserver.label;"
<label class="textbox-label" value="&sendingServer.label;"
control="outgoing_server"/>
<hbox>
<vbox id="outgoing_status" class="icon" width="22"/>
@ -337,9 +344,9 @@
disabled="true"
class="security">
<menupopup onpopuphidden="gEmailConfigWizard.setSecurity('outgoing_security')">
<menuitem label="&noencryption.label;" value="1"/>
<menuitem label="&noEncryption.label;" value="1"/>
<menuitem label="&starttls.label;" value="3"/>
<menuitem label="&ssltls2.label;" value="2"/>
<menuitem label="&sslTls.label;" value="2"/>
</menupopup>
</menulist>
</hbox>
@ -356,13 +363,14 @@
<hbox align="center">
<button id="cancel_button" label="&cancel.label;"
onmousedown="gEmailConfigWizard.onCancel();"/>
<label id="advanced_settings" value="&gotoadvanced2.label;"
<label id="advanced_settings" value="&createAndEditSettings.label;"
onmousedown="gEmailConfigWizard.advancedSettings()"
hidden="true" class="clickable_label"/>
</hbox>
<spacer flex="1"/>
<hbox align="center">
<button id="create_button" label="&createaccount.label;"
<button id="create_button" label="&createAccount.label;"
accesskey="&createAccount.accesskey;"
onmousedown="gEmailConfigWizard.onOK();"
hidden="true" class="larger-button"/>
</hbox>
@ -384,11 +392,12 @@
<vbox class="settings">
<description id="incoming_details"/>
<hbox>
<label value="&incoming_settings.label;"/><label id="incoming_settings"/>
<label value="&incomingSettings.label;"/><label id="incomingSettings"/>
</hbox>
<checkbox id="acknowledge_incoming"
class="acknowledge_checkbox"
label="&incoming_is_checked2.label;"
label="&confirmIncomingWarning.label;"
accesskey="&confirmIncomingWarning.accesskey;"
oncommand="gEmailConfigWizard.toggleAcknowledgeIncoming()"/>
</vbox>
</vbox>
@ -397,56 +406,29 @@
<vbox class="settings">
<description id="outgoing_details"/>
<hbox>
<label value="&outgoing_settings.label;"/><label id="outgoing_settings"/>
<label value="&outgoingSettings.label;"/><label id="outgoingSettings"/>
</hbox>
<checkbox id="acknowledge_outgoing"
class="acknowledge_checkbox"
label="&outgoing_is_checked2.label;"
label="&confirmOutgoingWarning.label;"
accesskey="&confirmOutgoingWarning.accesskey;"
oncommand="gEmailConfigWizard.toggleAcknowledgeOutgoing()"/>
</vbox>
</vbox>
<spacer flex="1"/>
<description id="findoutmore">&lectureYourProvider2.description;</description>
<description id="findoutmore">&contactYourProvider.description;</description>
</vbox>
<spacer flex="1"/>
<hbox>
<button id="getmeoutofhere" label="&getmeout2.label;" oncommand="gEmailConfigWizard.getMeOutOfHere()"/>
<button id="getmeoutofhere" label="&changeSettings.label;"
accesskey="&changeSettings.accesskey;"
oncommand="gEmailConfigWizard.getMeOutOfHere()"/>
<spacer flex="1"/>
<button id="iknow" label="&understood2.label;" disabled="true" oncommand="gEmailConfigWizard.validateAndFinish()"/>
<button id="iknow" label="&createAccount.label;" disabled="true"
accesskey="&createAccount.accesskey;"
oncommand="gEmailConfigWizard.validateAndFinish()"/>
</hbox>
</vbox>
</hbox>
</vbox>
<vbox id="customfields-box" hidden="true" flex="1">
<description class="header">&customfields-header.label;</description>
<description class="intro">&customfields-intro1.descr;</description>
<description class="intro">&customfields-intro2.descr;</description>
<spacer flex="1"/>
<grid>
<columns>
<column/>
<column flex="1"/>
<column/>
</columns>
<rows id="customfields-rows">
<!-- Generated N times by JS via DOM:
<row align="top">
<description class="customfield-label">Text from config file</description>
<textfield id="customfields-value-FIELDID" class="customfield-value" value="Default from config file"/>
<label class="customfield-example" value="Example value from config file"/>
</row>
-->
</rows>
</grid>
<spacer flex="1"/>
<description id="customfields-error" class="errordescription"/>
<spacer/>
<hbox>
<button label="&customfields-cancel.label;" oncommand="gCustomFieldsDialog.onCancel();"/>
<spacer flex="1"/>
<button label="&customfields-ok.label;" oncommand="gCustomFieldsDialog.onOK();"/>
</hbox>
</vbox>
</window>

Просмотреть файл

@ -183,7 +183,7 @@ FetchHTTP.prototype =
catch (e)
{
success = false;
let stringBundle = getStringBundle("chrome://messenger/content/accountCreationUtil.properties");
let stringBundle = getStringBundle("chrome://messenger/locale/accountCreationUtil.properties");
errorStr = stringBundle.GetStringFromName("bad_response_content.error");
errorCode = -4;
}
@ -198,7 +198,7 @@ FetchHTTP.prototype =
} catch (e) {
// If we can't resolve the hostname in DNS etc., .statusText throws
errorCode = -2;
let stringBundle = getStringBundle("chrome://messenger/content/accountCreationUtil.properties")
let stringBundle = getStringBundle("chrome://messenger/locale/accountCreationUtil.properties")
errorStr = stringBundle.GetStringFromName("cannot_contact_server.error");
ddump(errorStr);
}

Просмотреть файл

@ -392,7 +392,7 @@ HostDetector.prototype =
{
// Ran out of options.
this._log.info("ran out of hosts");
var stringBundle = getStringBundle("chrome://messenger/content/accountCreationModel.properties");
var stringBundle = getStringBundle("chrome://messenger/locale/accountCreationModel.properties");
var errorMsg = stringBundle.GetStringFromName("cannot_find_server.error");
this.mErrorCallback(new Exception(errorMsg));
return;

Просмотреть файл

@ -53,7 +53,7 @@ function readFromXML(clientConfigXML)
{
if (!"emailProvider" in clientConfigXML)
{
var stringBundle = getStringBundle("chrome://messenger/content/accountCreationModel.properties");
var stringBundle = getStringBundle("chrome://messenger/locale/accountCreationModel.properties");
throw stringBundle.GetStringFromName("no_emailProvider.error");
}
var xml = clientConfigXML.emailProvider;
@ -89,7 +89,7 @@ function readFromXML(clientConfigXML)
var oO = d.outgoing; // output (object)
if (!(oX.@type == "smtp"))
{
var stringBundle = getStringBundle("chrome://messenger/content/accountCreationModel.properties");
var stringBundle = getStringBundle("chrome://messenger/locale/accountCreationModel.properties");
throw stringBundle.GetStringFromName("outgoing_not_smtp.error");
}
oO.hostname = sanitize.hostname(oX.hostname);

Просмотреть файл

@ -169,7 +169,7 @@ var sanitize =
if (allowedValue == unchecked)
return allowedValue;
}
throw new MalformedException("enum_value2.error", unchecked);
throw new MalformedException("allowed_value.error", unchecked);
},
/**
@ -190,13 +190,13 @@ var sanitize =
if (inputValue == unchecked)
return mapping[inputValue];
}
throw new MalformedException("enum_value2.error", unchecked);
throw new MalformedException("allowed_value.error", unchecked);
}
};
function MalformedException(msgID, uncheckedBadValue)
{
var stringBundle = getStringBundle("chrome://messenger/content/accountCreationUtil.properties");
var stringBundle = getStringBundle("chrome://messenger/locale/accountCreationUtil.properties");
this._message = stringBundle.GetStringFromName(msgID);
if (kDebug)
this._message += " (bad value: " + new String(uncheckedBadValue) + ")";

Просмотреть файл

@ -161,7 +161,7 @@ urlListener.prototype =
else if (!this.mAlter)
{
this._cleanup();
var stringBundle = getStringBundle("chrome://messenger/content/accountCreationModel.properties");
var stringBundle = getStringBundle("chrome://messenger/locale/accountCreationModel.properties");
var errorMsg = stringBundle.GetStringFromName("cannot_login.error");
this.mErrorCallback(new Exception(errorMsg));
}
@ -202,7 +202,7 @@ urlListener.prototype =
{
// Tried all variations we can. Give up.
this._cleanup();
let stringBundle = getStringBundle("chrome://messenger/content/accountCreationModel.properties");
let stringBundle = getStringBundle("chrome://messenger/locale/accountCreationModel.properties");
let errorMsg = stringBundle.GetStringFromName("cannot_login.error");
this.mErrorCallback(new Exception(errorMsg));
}
@ -239,7 +239,7 @@ urlListener.prototype =
ddump("exceptionAdded = " + params.exceptionAdded + "\n");
if (!params.exceptionAdded) {
self._cleanup();
let stringBundle = getStringBundle("chrome://messenger/content/accountCreationModel.properties");
let stringBundle = getStringBundle("chrome://messenger/locale/accountCreationModel.properties");
let errorMsg = stringBundle.GetStringFromName("cannot_login.error");
self.mErrorCallback(new Exception(errorMsg));
}