From 2dff18c7d7ef6bea315fcdf96583f60a0a7b8594 Mon Sep 17 00:00:00 2001 From: "timeless%mozdev.org" Date: Tue, 7 Oct 2003 09:00:40 +0000 Subject: [PATCH] Bug 201469 Add smtp server's username field to Account Wizard patch by bugzilla@arlen.demon.co.uk r=neil sr=bienvenu --- .../prefs/resources/content/AccountWizard.js | 8 +-- .../prefs/resources/content/AccountWizard.xul | 42 ++++++++++++--- .../base/prefs/resources/content/aw-done.js | 16 +++--- .../base/prefs/resources/content/aw-login.js | 53 +++++++++++++++++-- .../base/prefs/resources/content/aw-server.js | 36 +++++-------- .../resources/locale/en-US/AccountWizard.dtd | 34 ++++++++---- 6 files changed, 138 insertions(+), 51 deletions(-) diff --git a/mailnews/base/prefs/resources/content/AccountWizard.js b/mailnews/base/prefs/resources/content/AccountWizard.js index 5d2fcfce1141..9ac70dab0a41 100644 --- a/mailnews/base/prefs/resources/content/AccountWizard.js +++ b/mailnews/base/prefs/resources/content/AccountWizard.js @@ -303,8 +303,8 @@ function AccountDataToPageData(accountData, pageData) if (accountData.smtp) { smtp = accountData.smtp; - setPageData(pageData, "server", "smtphostname", - smtp.hostname); + setPageData(pageData, "server", "smtphostname", smtp.hostname); + setPageData(pageData, "login", "smtpusername", smtp.username); } } @@ -341,6 +341,8 @@ function PageDataToAccountData(pageData, accountData) server.password = pageData.login.password.value; if (pageData.login.rememberPassword) server.rememberPassword = pageData.login.rememberPassword.value; + if (pageData.login.smtpusername) + smtp.username = pageData.login.smtpusername.value; } dump("pageData.server = " + pageData.server + "\n"); @@ -886,7 +888,7 @@ function FixupAccountDataForIsp(accountData) accountData.smtpRequiresUsername) { // fix for bug #107953 // if incoming hostname is same as smtp hostname - // use the server username (insetad of the email username) + // use the server username (instead of the email username) if (accountData.smtp.hostname == accountData.incomingServer.hostName) accountData.smtp.username = accountData.incomingServer.username; else diff --git a/mailnews/base/prefs/resources/content/AccountWizard.xul b/mailnews/base/prefs/resources/content/AccountWizard.xul index 7e645c3cca87..7d550f101e6c 100644 --- a/mailnews/base/prefs/resources/content/AccountWizard.xul +++ b/mailnews/base/prefs/resources/content/AccountWizard.xul @@ -156,7 +156,8 @@ Rights Reserved. - &haveSmtp1.label; + * @@ -175,6 +176,29 @@ Rights Reserved. accesskey="&usernameLabel.accesskey;" control="username"/> + + + + + &usernameSmtpDesc.label; + + + + + + + + + @@ -224,17 +248,17 @@ Rights Reserved. - - - - + + + +