diff --git a/mozilla/mail/base/content/contents.rdf.in b/mozilla/mail/base/content/contents.rdf old mode 100755 new mode 100644 similarity index 97% rename from mozilla/mail/base/content/contents.rdf.in rename to mozilla/mail/base/content/contents.rdf index 234556e79b7..a771c19b24c --- a/mozilla/mail/base/content/contents.rdf.in +++ b/mozilla/mail/base/content/contents.rdf @@ -13,7 +13,7 @@ chrome:displayName="Messenger" chrome:author="mozilla.org" chrome:name="messenger" - chrome:localeVersion="@MOZILLA_LOCALE_VERSION@" +#expand chrome:localeVersion="__MOZILLA_LOCALE_VERSION__" chrome:skinVersion="1.5"> diff --git a/mozilla/mail/base/content/help.rdf.in b/mozilla/mail/base/content/help.rdf old mode 100755 new mode 100644 similarity index 88% rename from mozilla/mail/base/content/help.rdf.in rename to mozilla/mail/base/content/help.rdf index 9d46f9ff167..86bbce05d1c --- a/mozilla/mail/base/content/help.rdf.in +++ b/mozilla/mail/base/content/help.rdf @@ -10,6 +10,6 @@ chrome:displayName="Mozilla Help Viewer" chrome:author="netscape.com" chrome:name="help" - chrome:localeVersion="@MOZILLA_LOCALE_VERSION@"> +#expand chrome:localeVersion="__MOZILLA_LOCALE_VERSION__"> diff --git a/mozilla/mail/base/content/mailWindowOverlay.js b/mozilla/mail/base/content/mailWindowOverlay.js index 697489fd944..57bd945b04a 100644 --- a/mozilla/mail/base/content/mailWindowOverlay.js +++ b/mozilla/mail/base/content/mailWindowOverlay.js @@ -518,9 +518,6 @@ function SetMenuItemLabel(menuItemId, customLabel) function InitMessageLabel(menuType) { - /* this code gets the label strings and changes the menu labels */ - var prefs = Components.classes["@mozilla.org/preferences;1"].getService(Components.interfaces.nsIPref); - var prefBranch = prefs.getDefaultBranch(null); var color; try @@ -561,7 +558,7 @@ function InitMessageLabel(menuType) { try { - var prefString = prefs.getComplexValue("mailnews.labels.description." + label, + var prefString = gPrefBranch.getComplexValue("mailnews.labels.description." + label, Components.interfaces.nsIPrefLocalizedString); var formattedPrefString = gMessengerBundle.getFormattedString("labelMenuItemFormat" + label, [prefString], 1); diff --git a/mozilla/mail/base/content/mailWindowOverlay.xul b/mozilla/mail/base/content/mailWindowOverlay.xul index 07f33f48399..3409a7a12ef 100644 --- a/mozilla/mail/base/content/mailWindowOverlay.xul +++ b/mozilla/mail/base/content/mailWindowOverlay.xul @@ -704,8 +704,8 @@ + onpopupshowing="if (event.target != this) return true; gContextMenu = new nsContextMenu(this); return fillMessagePaneContextMenu();" + onpopuphiding="if (event.target == this) gContextMenu = null;"> diff --git a/mozilla/mail/base/content/msgHdrViewOverlay.js b/mozilla/mail/base/content/msgHdrViewOverlay.js index e114f0afce8..6306b87a64a 100644 --- a/mozilla/mail/base/content/msgHdrViewOverlay.js +++ b/mozilla/mail/base/content/msgHdrViewOverlay.js @@ -98,7 +98,7 @@ var gCollapsedHeaderList = [ {name:"subject", outputFunction:updateHeaderValueIn // We also have an expanded header view. This shows many of your more common (and useful) headers. var gExpandedHeaderList = [ {name:"subject"}, {name:"from", outputFunction:OutputEmailAddresses}, - {name:"reply-to", isEmailAddress:true, outputFunction:OutputEmailAddresses}, + {name:"reply-to", outputFunction:OutputEmailAddresses}, {name:"date"}, {name:"to", useToggle:true, outputFunction:OutputEmailAddresses}, {name:"cc", useToggle:true, outputFunction:OutputEmailAddresses}, @@ -109,8 +109,8 @@ var gExpandedHeaderList = [ {name:"subject"}, // Now, for each view the message pane can generate, we need a global table of headerEntries. These // header entry objects are generated dynamically based on the static date in the header lists (see above) // and elements we find in the DOM based on properties in the header lists. -var gCollapsedHeaderView = new Array; -var gExpandedHeaderView = new Array; +var gCollapsedHeaderView = {}; +var gExpandedHeaderView = {}; // currentHeaderData --> this is an array of header name and value pairs for the currently displayed message. // it's purely a data object and has no view information. View information is contained in the view objects. @@ -172,16 +172,13 @@ function initializeHeaderViewTables() { // iterate over each header in our header list arrays and create header entries // for each one. These header entries are then stored in the appropriate header table - - if (!gCollapsedHeaderView.length) // if we haven't already initialized the collapsed view... - for (var index = 0; index < gCollapsedHeaderList.length; index++) + var index; + for (index = 0; index < gCollapsedHeaderList.length; index++) { gCollapsedHeaderView[gCollapsedHeaderList[index].name] = new createHeaderEntry('collapsed', gCollapsedHeaderList[index]); } - if (!gExpandedHeaderView.length) - { for (index = 0; index < gExpandedHeaderList.length; index++) { var headerName = gExpandedHeaderList[index].name; @@ -199,7 +196,6 @@ function initializeHeaderViewTables() var userAgentEntry = {name:"user-agent", outputFunction:updateHeaderValue}; gExpandedHeaderView[userAgentEntry.name] = new createHeaderEntry('expanded', userAgentEntry); } - } // if we need to initialize the expanded header view... } function OnLoadMsgHeaderPane() @@ -419,7 +415,7 @@ function EnsureSubjectValue() function CheckNotify() { - if (this.NotifyClearAddresses != undefined) + if ("NotifyClearAddresses" in this) NotifyClearAddresses(); } @@ -559,7 +555,7 @@ function UpdateMessageHeaders() for (headerName in currentHeaderData) { var headerField = currentHeaderData[headerName]; - var headerEntry; + var headerEntry = null; if (headerName == "subject") { @@ -576,30 +572,28 @@ function UpdateMessageHeaders() if (gCollapsedHeaderViewMode && !gBuiltCollapsedView) { + if (headerName in gCollapsedHeaderView) headerEntry = gCollapsedHeaderView[headerName]; - if (headerEntry != undefined && headerEntry) - { - headerEntry.outputFunction(headerEntry, headerField.headerValue); - headerEntry.valid = true; - } } else if (!gCollapsedHeaderViewMode && !gBuiltExpandedView) { + if (headerName in gExpandedHeaderView) headerEntry = gExpandedHeaderView[headerName]; - if (headerEntry == undefined && gViewAllHeaders) + + if (!headerEntry && gViewAllHeaders) { // for view all headers, if we don't have a header field for this value....cheat and create one....then // fill in a headerEntry gExpandedHeaderView[headerName] = new createNewHeaderView(headerName); headerEntry = gExpandedHeaderView[headerName]; } + } // if we are in expanded view.... - if (headerEntry != undefined && headerEntry) + if (headerEntry) { headerEntry.outputFunction(headerEntry, headerField.headerValue); headerEntry.valid = true; } - } // if we are in expanded view.... } if (gCollapsedHeaderViewMode) @@ -610,7 +604,7 @@ function UpdateMessageHeaders() // now update the view to make sure the right elements are visible updateHeaderViews(); - if (this.FinishEmailProcessing != undefined) + if ("FinishEmailProcessing" in this) FinishEmailProcessing(); } @@ -774,7 +768,7 @@ function updateEmailAddressNode(emailAddressNode, emailAddress, fullAddress, dis emailAddressNode.setTextAttribute("fullAddress", fullAddress); emailAddressNode.setTextAttribute("displayName", displayName); - if (this.AddExtraAddressProcessing != undefined) + if ("AddExtraAddressProcessing" in this) AddExtraAddressProcessing(emailAddress, emailAddressNode); } diff --git a/mozilla/mail/base/content/msgMail3PaneWindow.js b/mozilla/mail/base/content/msgMail3PaneWindow.js index a25f55d8934..b612ed22f19 100644 --- a/mozilla/mail/base/content/msgMail3PaneWindow.js +++ b/mozilla/mail/base/content/msgMail3PaneWindow.js @@ -745,18 +745,11 @@ function delayedOnLoadMessenger() // argument[0] --> folder uri // argument[1] --> optional message key // argument[2] --> optional email address; //will come from aim; needs to show msgs from buddy's email address - if ("arguments" in window && window.arguments[0]) + if ("arguments" in window) { - gStartFolderUri = window.arguments[0]; - gStartMsgKey = window.arguments[1]; - gSearchEmailAddress = window.arguments[2]; - - } - else - { - gStartFolderUri = null; - gStartMsgKey = nsMsgKey_None; - gSearchEmailAddress = null; + gStartFolderUri = (window.arguments.length > 0) ? window.arguments[0] : null; + gStartMsgKey = (window.arguments.length > 1) ? window.arguments[1]: nsMsgKey_None; + gSearchEmailAddress = (window.arguments.length > 2) ? window.arguments[2] : null; } setTimeout("loadStartFolder(gStartFolderUri);", 0); diff --git a/mozilla/mail/base/content/navigator.rdf.in b/mozilla/mail/base/content/navigator.rdf.in deleted file mode 100755 index 33dd9909142..00000000000 --- a/mozilla/mail/base/content/navigator.rdf.in +++ /dev/null @@ -1,20 +0,0 @@ - - - - - - - - - - - - - -