Bug 309068 Aim URL presence check should be disabled by default. r=mnyromyr,sr=neil.parkwaycc.co.uk

This commit is contained in:
bugzilla%standard8.demon.co.uk 2005-11-25 17:37:38 +00:00
Родитель fd4d83103d
Коммит 225781b66b
5 изменённых файлов: 32 добавлений и 6 удалений

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

@ -231,10 +231,11 @@ function DisplayCardViewPane(card)
visible = HandleLink(data.cvEmail1, zPrimaryEmail, card.primaryEmail, data.cvEmail1Box, "mailto:" + card.primaryEmail) || visible; visible = HandleLink(data.cvEmail1, zPrimaryEmail, card.primaryEmail, data.cvEmail1Box, "mailto:" + card.primaryEmail) || visible;
} }
var onlineCheckAllowed = gPrefs.getBoolPref("mail.addr_book.im.online_check_allowed");
var goimURL = "aim:goim?screenname=" + card.aimScreenName; var goimURL = "aim:goim?screenname=" + card.aimScreenName;
var hasScreenName = HandleLink(data.cvScreenname, zScreenName, card.aimScreenName, data.cvScreennameBox, goimURL); var hasScreenName = HandleLink(data.cvScreenname, zScreenName, card.aimScreenName, data.cvScreennameBox, goimURL);
if (!hasScreenName || gIOService.offline) { if (!onlineCheckAllowed || !hasScreenName || gIOService.offline) {
data.cvAimPresence.removeAttribute("src"); data.cvAimPresence.removeAttribute("src");
data.cvAimPresence.removeAttribute("url"); data.cvAimPresence.removeAttribute("url");
data.cvAimPresence.setAttribute("width","0"); data.cvAimPresence.setAttribute("width","0");

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

@ -59,6 +59,7 @@ const kLastNameFirst = 1;
const kFirstNameFirst = 2; const kFirstNameFirst = 2;
const kLDAPDirectory = 0; // defined in nsDirPrefs.h const kLDAPDirectory = 0; // defined in nsDirPrefs.h
const kPABDirectory = 2; // defined in nsDirPrefs.h const kPABDirectory = 2; // defined in nsDirPrefs.h
const kPrefOnlineCheckAllowed = "mail.addr_book.im.online_check_allowed";
// Note: We need to keep this listener as it does not just handle dir // Note: We need to keep this listener as it does not just handle dir
// pane deletes but also deletes of address books and lists from places like // pane deletes but also deletes of address books and lists from places like
@ -273,6 +274,8 @@ function GetCurrentPrefs()
document.getElementById("cmd_SortBy_PhoneticName") document.getElementById("cmd_SortBy_PhoneticName")
.setAttribute("hidden", "false"); .setAttribute("hidden", "false");
document.getElementById("menu_allow_online_check")
.setAttribute("checked", gPrefs.getBoolPref(kPrefOnlineCheckAllowed));
} }
@ -899,3 +902,14 @@ function AbIMSelected()
LaunchUrl(url); LaunchUrl(url);
} }
function onAllowOnlineCheck(target)
{
// Update the pref
gPrefs.setBoolPref(kPrefOnlineCheckAllowed,
document.getElementById("menu_allow_online_check")
.getAttribute("checked") == "true");
// Now redisplay the card view pane.
UpdateCardView();
}

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

@ -372,6 +372,12 @@
<menuitem label="&importCmd.label;" accesskey="&importCmd.accesskey;" oncommand="toImport()"/> <menuitem label="&importCmd.label;" accesskey="&importCmd.accesskey;" oncommand="toImport()"/>
<menuitem label="&exportCmd.label;" accesskey="&exportCmd.accesskey;" oncommand="AbExport()"/> <menuitem label="&exportCmd.label;" accesskey="&exportCmd.accesskey;" oncommand="AbExport()"/>
<menuseparator/> <menuseparator/>
<menuitem label="&allowOnlineCheck.label;"
accesskey="&allowOnlineCheck.accesskey;"
id="menu_allow_online_check"
oncommand="onAllowOnlineCheck(event.target);"
type="checkbox"/>
<menuseparator/>
</menupopup> </menupopup>
</menu> </menu>

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

@ -55,10 +55,6 @@
<!-- LOCALIZATION NOTE (newLDAPDirectoryCmd.accesskey) : DONT_TRANSLATE --> <!-- LOCALIZATION NOTE (newLDAPDirectoryCmd.accesskey) : DONT_TRANSLATE -->
<!ENTITY newLDAPDirectoryCmd.accesskey "D"> <!ENTITY newLDAPDirectoryCmd.accesskey "D">
<!ENTITY newIM.label "IM"> <!ENTITY newIM.label "IM">
<!ENTITY importCmd.label "Import...">
<!ENTITY importCmd.accesskey "I">
<!ENTITY exportCmd.label "Export...">
<!ENTITY exportCmd.accesskey "E">
<!ENTITY printCardViewCmd.label "Print Card..."> <!ENTITY printCardViewCmd.label "Print Card...">
<!ENTITY printCardViewCmd.accesskey "p"> <!ENTITY printCardViewCmd.accesskey "p">
<!ENTITY printPreviewCardViewCmd.label "Print Preview Card"> <!ENTITY printPreviewCardViewCmd.label "Print Preview Card">
@ -102,6 +98,14 @@
<!ENTITY displayNameCmd.label "Display Name"> <!ENTITY displayNameCmd.label "Display Name">
<!ENTITY displayNameCmd.accesskey "d"> <!ENTITY displayNameCmd.accesskey "d">
<!-- Tasks Menu -->
<!ENTITY importCmd.label "Import...">
<!ENTITY importCmd.accesskey "I">
<!ENTITY exportCmd.label "Export...">
<!ENTITY exportCmd.accesskey "E">
<!ENTITY allowOnlineCheck.label "Check online presence (AOL)">
<!ENTITY allowOnlineCheck.accesskey "C">
<!ENTITY stopSearchingCmd.label ".Stop Searching"> <!ENTITY stopSearchingCmd.label ".Stop Searching">
<!-- Toolbar and Popup items --> <!-- Toolbar and Popup items -->

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

@ -137,6 +137,7 @@ pref("mail.file_attach_binary", false);
pref("mail.show_headers", 1); // some pref("mail.show_headers", 1); // some
pref("mail.pane_config", 0); pref("mail.pane_config", 0);
pref("mail.addr_book.mapit_url.format", "chrome://messenger-region/locale/region.properties"); pref("mail.addr_book.mapit_url.format", "chrome://messenger-region/locale/region.properties");
pref("mail.addr_book.im.online_check_allowed", false);
// the format for "mail.addr_book.quicksearchquery.format" is: // the format for "mail.addr_book.quicksearchquery.format" is:
// @V == the escaped value typed in the quick search bar in the addressbook // @V == the escaped value typed in the quick search bar in the addressbook