Bug 518077 - Add custom settings for "sign in" to set things like server url

Provide an initial implementation to read and set preferences: autoconnect, serverURL. For now show them in a "Custom settings" expando tab like the one for create account, but the styling isn't great.

--HG--
extra : rebase_source : 3fc1e8bad7786cf06e2da8c95e7bca5f50fb6ec3
This commit is contained in:
Edward Lee 2009-09-22 01:00:43 -07:00
parent 2c3554a154
commit 2fbfee64a6

View File

@ -215,7 +215,15 @@ WeaveSvc.prototype = {
set passphrase passphrase(value) ID.get("WeaveCryptoID").password = value,
get serverURL() Svc.Prefs.get("serverURL"),
set serverURL(value) Svc.Prefs.set("serverURL", value),
set serverURL(value) {
// Only do work if it's actually changing
if (value == this.serverURL)
return;
// A new server most likely uses a different cluster, so clear that
Svc.Prefs.set("serverURL", value);
Svc.Prefs.reset("clusterURL");
},
get clusterURL() Svc.Prefs.get("clusterURL", ""),
set clusterURL(value) {