--HG--
branch : gloda-facet
This commit is contained in:
Andrew Sutherland 2009-09-07 14:34:49 -07:00
Родитель e1345e9cc7 aabfdf61ba
Коммит c09e9852e1
132 изменённых файлов: 1549 добавлений и 1435 удалений

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

@ -1 +1 @@
c6a1b52b3e3f7bfb72984e227c821aff3d1c59d5
3786d789303cc727aabf6728454556705232a33e

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

@ -1 +1 @@
b11a45aa831d50594e7f23968bda9bc010103ef1
23f393649289dd4774ddd1d231b01e1de8a75cfe

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

@ -1 +1 @@
b7a1e8bc053a177768b2af5c4c8c3176163a1321
45fbab07d8b3e6cf7fb227e5783b1a5dcdc141d5

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

@ -83,9 +83,7 @@
<xul:label anonid="event-name"
crop="end"
flex="1"
style="margin: 0;">
<html:div anonid="event-name-div"/>
</xul:label>
style="margin: 0;"/>
<xul:textbox anonid="event-name-textbox"
class="plain calendar-event-name-textbox"
crop="end"

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

@ -1913,10 +1913,7 @@
xbl:inherits="context,parentorient=orient,readonly,flashing,alarm,allday,priority,progress,status,calendar,categories">
<xul:image flex="1" class="calendar-event-box-gradient"/>
<xul:vbox class="calendar-event-details" anonid="calendar-event-details">
<xul:description anonid="event-name" class="calendar-event-details-core" flex="1">
<html:div anonid="event-name-div"/>
</xul:description>
<xul:description anonid="event-name" class="calendar-event-details-core" flex="1"/>
<xul:textbox anonid="event-name-textbox"
class="plain calendar-event-details-core calendar-event-name-textbox"
flex="1"
@ -2033,24 +2030,19 @@
<method name="setEditableLabel">
<body><![CDATA[
let evldiv = document.getAnonymousElementByAttribute(this, "anonid", "event-name-div");
let item = this.mOccurrence;
var evl = this.eventNameLabel;
var item = this.mOccurrence;
if (item.title && item.title != "") {
// Use <description> textContent so it can wrap.
evldiv.textContent = item.title;
evl.textContent = item.title;
} else {
evldiv.textContent = calGetString("calendar", "eventUntitled");
evl.textContent = calGetString("calendar", "eventUntitled");
}
var gripbar = document.getAnonymousElementByAttribute(this, "anonid", "gripbar1").boxObject.height;
var height = document.getAnonymousElementByAttribute(this, "anonid", "eventbox").boxObject.height;
if(this.orient == "vertical") {
evldiv.setAttribute("style", "max-height: " + Math.max(0, height-gripbar*2) + "px");
} else {
evldiv.setAttribute("style", "max-height: " + height + "px");
}
evl.setAttribute("style", "max-height: " + Math.max(0, height-gripbar*2) + "px");
]]></body>
</method>
</implementation>

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

@ -68,9 +68,7 @@
<xul:label anonid="event-name"
crop="end"
flex="1"
style="margin: 0;">
<html:div anonid="event-name-div"/>
</xul:label>
style="margin: 0;"/>
<xul:textbox anonid="event-name-textbox"
class="plain"
crop="end"
@ -178,13 +176,13 @@
<method name="setEditableLabel">
<body><![CDATA[
let evldiv = document.getAnonymousElementByAttribute(this, "anonid", "event-name-div");
let item = this.mOccurrence;
var evl = this.eventNameLabel;
var item = this.mOccurrence;
if (item.title && item.title != "") {
evldiv.textContent = item.title;
evl.value = item.title;
} else {
evldiv.textContent = calGetString("calendar", "eventUntitled");
evl.value = calGetString("calendar", "eventUntitled")
}
]]></body>
</method>
@ -244,7 +242,7 @@
// status attribute
if (item.status) {
this.setAttribute("status", item.status.toUpperCase());
this.setAttribute("status", item.status.toLowerCase());
}
// calendar name

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

@ -417,6 +417,39 @@ cal.toRFC3339 = function toRFC3339(aDateTime) {
return str;
};
/**
* Observer bag implementation taking care to replay open batch notifications.
*/
cal.observerBag = function calObserverBag(iid) {
this.init(iid);
};
cal.observerBag.prototype = {
__proto__: cal.calListenerBag.prototype,
mBatchCount: 0,
notify: function calObserverBag_notify(func, args) {
switch (func) {
case "onStartBatch":
++this.mBatchCount;
break;
case "onEndBatch":
--this.mBatchCount;
break;
}
return this.__proto__.__proto__.notify.apply(this, arguments);
},
add: function calObserverBag_add(iface) {
if (this.__proto__.__proto__.add.apply(this, arguments) && (this.mBatchCount > 0)) {
// Replay batch notifications, because the onEndBatch notifications are yet to come.
// We may think about doing the reverse on remove, though I currently see no need:
for (var i = this.mBatchCount; i--;) {
iface.onStartBatch();
}
}
}
};
/**
* Base prototype to be used implementing a provider.
*
@ -450,7 +483,7 @@ cal.ProviderBase.prototype = {
initProviderBase: function cPB_initProviderBase() {
this.wrappedJSObject = this;
this.mObservers = new cal.calListenerBag(Components.interfaces.calIObserver);
this.mObservers = new cal.observerBag(Components.interfaces.calIObserver);
this.mProperties = {};
this.mProperties.currentStatus = Components.results.NS_OK;
},

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

@ -608,6 +608,8 @@ calAlarm.prototype = {
return aPrefix + "Event";
} else if (isToDo(aItem)) {
return aPrefix + "Task";
} else {
return aPrefix;
}
}
@ -663,6 +665,10 @@ calAlarm.prototype = {
"reminderCustomTitle",
[unitString, originString]);
} else {
// This is an incomplete alarm, but then again we should never reach
// this state.
return "[Incomplete calIAlarm]";
}
}
};

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

@ -35,6 +35,8 @@
*
* ***** END LICENSE BLOCK ***** */
Components.utils.import("resource://calendar/modules/calProviderUtils.jsm");
function calCachedCalendarObserverHelper(home, isCachedObserver) {
this.home = home;
this.isCachedObserver = isCachedObserver;
@ -104,7 +106,7 @@ calCachedCalendarObserverHelper.prototype = {
function calCachedCalendar(uncachedCalendar) {
this.wrappedJSObject = this;
this.mSyncQueue = [];
this.mObservers = new calListenerBag(Components.interfaces.calIObserver);
this.mObservers = new cal.observerBag(Components.interfaces.calIObserver);
uncachedCalendar.superCalendar = this;
uncachedCalendar.addObserver(new calCachedCalendarObserverHelper(this, false));
this.mUncachedCalendar = uncachedCalendar;

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

@ -1190,8 +1190,10 @@ calInterfaceBag.prototype = {
}
if (!this.mInterfaces.some(eq)) {
this.mInterfaces.push(iface);
return true;
}
}
return false;
},
remove: function calInterfaceBag_remove(iface) {

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

@ -420,10 +420,6 @@ calendar-month-day-box-item[selected="true"] .calendar-event-selection {
min-height: 13px;
}
calendar-month-day-box-item[selected="true"] .calendar-color-box {
color: #000000;
}
.calendar-month-day-box-item-label {
padding: 0px;
margin: 0px;
@ -594,24 +590,14 @@ calendar-month-day-box-item[invitation-status="NEEDS-ACTION"] {
calendar-event-box[invitation-status="TENTATIVE"],
calendar-editable-item[invitation-status="TENTATIVE"],
calendar-month-day-box-item[invitation-status="TENTATIVE"],
calendar-event-box[status="TENTATIVE"],
calendar-editable-item[status="TENTATIVE"],
calendar-month-day-box-item[status="TENTATIVE"] {
calendar-month-day-box-item[invitation-status="TENTATIVE"] {
opacity: 0.5;
}
calendar-event-box[invitation-status="DECLINED"],
calendar-editable-item[invitation-status="DECLINED"],
calendar-month-day-box-item[invitation-status="DECLINED"],
calendar-event-box[status="CANCELLED"],
calendar-editable-item[status="CANCELLED"],
calendar-month-day-box-item[status="CANCELLED"] {
opacity: 0.5;
}
.calendar-event-box-container[status="CANCELLED"] div {
text-decoration: line-through;
calendar-month-day-box-item[invitation-status="DECLINED"] {
opacity: 0.3;
}
/* Navigation controls for the views */

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

@ -420,10 +420,6 @@ calendar-month-day-box-item[selected="true"] .calendar-event-selection {
min-height: 13px;
}
calendar-month-day-box-item[selected="true"] .calendar-color-box {
color: #000000;
}
.calendar-month-day-box-item-label {
padding: 0px;
margin: 0px;
@ -594,24 +590,14 @@ calendar-month-day-box-item[invitation-status="NEEDS-ACTION"] {
calendar-event-box[invitation-status="TENTATIVE"],
calendar-editable-item[invitation-status="TENTATIVE"],
calendar-month-day-box-item[invitation-status="TENTATIVE"],
calendar-event-box[status="TENTATIVE"],
calendar-editable-item[status="TENTATIVE"],
calendar-month-day-box-item[status="TENTATIVE"] {
calendar-month-day-box-item[invitation-status="TENTATIVE"] {
opacity: 0.6;
}
calendar-event-box[invitation-status="DECLINED"],
calendar-editable-item[invitation-status="DECLINED"],
calendar-month-day-box-item[invitation-status="DECLINED"],
calendar-event-box[status="CANCELLED"],
calendar-editable-item[status="CANCELLED"],
calendar-month-day-box-item[status="CANCELLED"] {
opacity: 0.5;
}
.calendar-event-box-container[status="CANCELLED"] div {
text-decoration: line-through;
calendar-month-day-box-item[invitation-status="DECLINED"] {
opacity: 0.3;
}
/* Navigation controls for the views */

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

@ -104,8 +104,8 @@ function calCompositeCalendar () {
this.wrappedJSObject = this;
this.mCalendars = new Array();
this.mCompositeObservers = new calListenerBag(Components.interfaces.calICompositeObserver);
this.mObservers = new calListenerBag(Components.interfaces.calIObserver);
this.mCompositeObservers = new cal.observerBag(Components.interfaces.calICompositeObserver);
this.mObservers = new cal.observerBag(Components.interfaces.calIObserver);
this.mDefaultCalendar = null;
this.mStatusObserver = null;
}
@ -604,6 +604,7 @@ var calCompositeCalendarModule = {
return;
Components.utils.import("resource://calendar/modules/calUtils.jsm");
Components.utils.import("resource://calendar/modules/calProviderUtils.jsm");
cal.loadScripts(["calUtils.js"], this.__parent__);
this.mUtilsLoaded = true;

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

@ -632,7 +632,7 @@ calICSCalendar.prototype = {
// old backups
var i;
for (i = 0; i < filteredFiles.length - numBackupFiles; ++i) {
file = backupDir.clone();
let file = backupDir.clone();
file.append(filteredFiles[i].name);
// This can fail because of some crappy code in nsILocalFile.

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

@ -64,7 +64,7 @@ calMemoryCalendar.prototype = {
},
initMemoryCalendar: function() {
this.mObservers = new calListenerBag(Components.interfaces.calIObserver);
this.mObservers = new cal.observerBag(Components.interfaces.calIObserver);
this.mItems = {};
this.mMetaData = new calPropertyBag();
},

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

@ -303,7 +303,7 @@ function run_test() {
var calArray = [];
calArray.push(getStorageCal());
calArray.push(getMemoryCal());
for each (cal in calArray) {
for each (let calendar in calArray) {
// implement listener
var count = 0;
var listener = {
@ -335,7 +335,7 @@ function run_test() {
}
};
// add item to calendar
cal.addItem(aItem, listener);
calendar.addItem(aItem, listener);
}
}
@ -350,7 +350,7 @@ function run_test() {
var calArray = [];
calArray.push(getStorageCal());
calArray.push(getMemoryCal());
for each (cal in calArray) {
for each (let calendar in calArray) {
// implement listener
var count = 0;
var returnedItem = null;
@ -383,7 +383,7 @@ function run_test() {
}
};
// add item to calendar
cal.addItem(aItem, listener);
calendar.addItem(aItem, listener);
}
}

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

@ -277,7 +277,6 @@ function test_interface() {
// deleteRecurrenceItemAt
rinfo.deleteRecurrenceItemAt(1);
itemString = item.icalString;
dump(itemString);
do_check_true(itemString.indexOf(EXDATE) < 0);
do_check_false(itemString.indexOf(RDATE) < 0);

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

@ -12,13 +12,14 @@
* License.
*
* The Original Code is Mozilla Calendar code.
*
*
* The Initial Developer of the Original Code is
* Fred Jendrzejewski <fred.jen@web.de>
* Portions created by the Initial Developer are Copyright (C) 2008
* the Initial Developer. All Rights Reserved.
*
* Contributor(s):
* Philipp Kewisch <mozilla@kewis.ch>
*
* Alternatively, the contents of this file may be used under the terms of
* either the GNU General Public License Version 2 or later (the "GPL"), or
@ -35,36 +36,29 @@
* ***** END LICENSE BLOCK ***** */
function run_test() {
var eventClass = Cc["@mozilla.org/calendar/event;1"];
var eventIID = Ci.calIEvent;
var relationClass = Cc["@mozilla.org/calendar/relation;1"];
var relationIID = Ci.calIRelation;
// Create Relation
var r1 = createRelation();
let r1 = cal.createRelation();
// Create Items
var e1 = eventClass.createInstance(eventIID);
var e2 = eventClass.createInstance(eventIID);
let e1 = cal.createEvent();
let e2 = cal.createEvent();
// Testing relation set/get.
var properties = ["item", "relType", "relId"];
var values = [e1, "PARENT", e2.id];
let properties = {
relType: "PARENT",
relId: e2.id
}
// Make sure test is valid
do_check_eq(properties.length, values.length);
for (var i = 0; i < properties.length; i++) {
r1[properties[i]] = values[i];
do_check_eq(r1[properties[i]], values[i]);
for (let [property, value] in Iterator(properties)) {
r1[property] = value;
do_check_eq(r1[property], value);
}
// Add relation to event
e1.addRelation(r1);
// Add 2nd attendee to event.
var r2 = relationClass.createInstance(relationIID);
// Add 2nd relation to event.
let r2 = cal.createRelation();
r2.relId = "myid2";
e1.addRelation(r2);
@ -79,25 +73,25 @@ function run_test() {
}
function checkRelations(event, expRel) {
var countObj = {}
var allRel = event.getRelations(countObj);
let countObj = {};
let allRel = event.getRelations(countObj);
do_check_eq(countObj.value, allRel.length);
do_check_eq(allRel.length, expRel.length);
// check if all expacted relations are found
for (var i = 0; i < expRel.length; i++) {
for (let i = 0; i < expRel.length; i++) {
do_check_neq(allRel.indexOf(expRel[i]), -1);
}
// Check if all found relations are expected
for (var i = 0; i < allRel.length; i++) {
for (let i = 0; i < allRel.length; i++) {
do_check_neq(expRel.indexOf(allRel[i]), -1);
}
}
function modifyRelations(event, oldRel) {
var allRel = event.getRelations({});
var rel = allRel[0];
let allRel = event.getRelations({});
let rel = allRel[0];
// modify the properties
rel.relType = "SIBLING";
@ -106,15 +100,10 @@ function modifyRelations(event, oldRel) {
// remove one relation
event.removeRelation(rel);
do_check_eq(event.getRelations({}).length, oldRel.length - 1);
// add one relation and remove all relations
event.addRelation(oldRel[0]);
event.removeAllRelations();
do_check_eq(event.getRelations({}), 0);
}

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

@ -1 +1 @@
1.2009f
1.2009l

Двоичные данные
calendar/timezones/timezones.sqlite

Двоичный файл не отображается.

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

@ -467,9 +467,6 @@ QT_CONFIG = @QT_CONFIG@
TK_CFLAGS = @TK_CFLAGS@
TK_LIBS = @TK_LIBS@
CAIRO_FT_CFLAGS = @CAIRO_FT_CFLAGS@
MOZ_TREE_FREETYPE = @MOZ_TREE_FREETYPE@
MOZ_ENABLE_GTK2 = @MOZ_ENABLE_GTK2@
MOZ_ENABLE_QT = @MOZ_ENABLE_QT@
MOZ_ENABLE_PHOTON = @MOZ_ENABLE_PHOTON@
@ -488,9 +485,6 @@ MOZ_ENABLE_DBUS = @MOZ_ENABLE_DBUS@
MOZ_GTHREAD_CFLAGS = @MOZ_GTHREAD_CFLAGS@
MOZ_GTHREAD_LIBS = @MOZ_GTHREAD_LIBS@
FT2_CFLAGS = @FT2_CFLAGS@
FT2_LIBS = @FT2_LIBS@
MOZ_PANGO_LIBS = @MOZ_PANGO_LIBS@
MOZ_XIE_LIBS = @MOZ_XIE_LIBS@

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

@ -129,6 +129,7 @@ dnl ========================================================
GLIB_VERSION=1.2.0
LIBIDL_VERSION=0.6.3
PERL_VERSION=5.006
CAIRO_VERSION=1.6.0
PANGO_VERSION=1.14.0
GTK2_VERSION=2.10.0
MAKE_VERSION=3.78
@ -5085,10 +5086,6 @@ then
else
PKG_CHECK_MODULES(MOZ_PANGO, pango >= $PANGO_VERSION pangoft2 >= $PANGO_VERSION)
AC_SUBST(MOZ_PANGO_LIBS)
PKG_CHECK_MODULES(FT2, freetype2 > 6.1.0 fontconfig)
AC_SUBST(FT2_CFLAGS)
AC_SUBST(FT2_LIBS)
fi
fi
@ -5530,13 +5527,7 @@ MOZ_ARG_ENABLE_BOOL(tree-freetype,
MOZ_TREE_FREETYPE=1,
MOZ_TREE_FREETYPE= )
if test -n "$MOZ_TREE_FREETYPE"; then
AC_DEFINE(MOZ_TREE_FREETYPE)
AC_SUBST(MOZ_TREE_FREETYPE)
FT2_CFLAGS="-I${MOZILLA_SRCDIR}/modules/freetype2/include"
CAIRO_FT_CFLAGS="-I${MOZILLA_SRCDIR}/modules/freetype2/include"
FT2_LIBS="${LIBXUL_DIST}/lib/freetype2.lib"
CAIRO_FT_LIBS = "${LIBXUL_DIST}/lib/freetype2.lib"
AC_SUBST(CAIRO_FT_CFLAGS)
fi
dnl ========================================================
@ -7178,14 +7169,12 @@ AC_CHECK_HEADERS(stdint.h inttypes.h sys/int_types.h)
if test "$MOZ_TREE_CAIRO"; then
AC_DEFINE(MOZ_TREE_CAIRO)
if test "$MOZ_X11"; then
CAIRO_FT_CFLAGS="$FT2_CFLAGS"
fi
if test "$MOZ_WIDGET_TOOLKIT" = "os2"; then
CAIRO_FT_CFLAGS="-I${MZFTCFGFT2}/include"
CAIRO_FT_LIBS="-L${MZFTCFGFT2}/lib -lmozft -lmzfntcfg"
fi
AC_SUBST(CAIRO_FT_CFLAGS)
if test "$MOZ_WIDGET_TOOLKIT" = "beos"; then
PKG_CHECK_MODULES(CAIRO_FT, fontconfig freetype2)
fi
if test "$_WIN32_MSVC"; then
MOZ_CAIRO_LIBS='$(DEPTH)/mozilla/gfx/cairo/cairo/src/mozcairo.lib $(DEPTH)/mozilla/gfx/cairo/libpixman/src/mozlibpixman.lib'
@ -7197,8 +7186,10 @@ if test "$MOZ_TREE_CAIRO"; then
fi
fi
else
PKG_CHECK_MODULES(CAIRO, cairo >= $CAIRO_VERSION freetype2 fontconfig)
MOZ_CAIRO_LIBS=$CAIRO_LIBS
if test "$MOZ_X11"; then
PKG_CHECK_MODULES(CAIRO_XRENDER, cairo-xlib-xrender >= $CAIRO_VERSION)
MOZ_CAIRO_LIBS="$MOZ_CAIRO_LIBS $XLDFLAGS $CAIRO_XRENDER_LIBS"
fi
fi

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

@ -60,6 +60,9 @@ var gViewSearchListener;
var gSearchStopButton;
// Should we try to search online?
var gSearchOnline = false;
// Controller object for search results thread pane
var nsSearchResultsController =
{
@ -348,9 +351,26 @@ function updateSearchFolderPicker(folderURI)
// use the URI to get the real folder
gCurrentFolder = GetMsgFolderFromUri(folderURI);
var searchLocalSystem = document.getElementById("checkSearchLocalSystem");
if (searchLocalSystem)
searchLocalSystem.disabled = gCurrentFolder.server.searchScope == nsMsgSearchScope.offlineMail;
var searchOnline = document.getElementById("checkSearchOnline");
if (searchOnline)
{
// We will clear and disable the search online checkbox if we are offline, or
// if the folder does not support online search.
// Anything greater than 0 is an online server like IMAP or news.
if (gCurrentFolder.server.offlineSupportLevel &&
!Components.classes["@mozilla.org/network/io-service;1"]
.getService(Components.interfaces.nsIIOService)
.offline)
{
searchOnline.disabled = false;
}
else
{
searchOnline.checked = false;
searchOnline.disabled = true;
}
}
setSearchScope(GetScopeForFolder(gCurrentFolder));
}
@ -392,6 +412,7 @@ function onSearch()
viewWrapper.beginViewUpdate();
viewWrapper.search.userTerms = searchTerms.length ? searchTerms : null;
viewWrapper.search.onlineSearch = gSearchOnline;
viewWrapper.searchFolders = getSearchFolders();
viewWrapper.endViewUpdate();
}
@ -486,11 +507,69 @@ function AddSubFoldersToURI(folder)
return returnString;
}
/**
* Determine the proper search scope to use for a folder, so that the user is
* presented with a correct list of search capabilities. The user may manually
* request on online search for certain server types. To determine if the
* folder body may be searched, we ignore whether autosync is enabled,
* figuring that after the user manually syncs, they would still expect that
* body searches would work.
*
* The available search capabilities also depend on whether the user is
* currently online or offline. Although that is also checked by the server,
* we do it ourselves because we have a more complex response to offline
* than the server's searchScope attribute provides.
*
* This method only works for real folders.
*/
function GetScopeForFolder(folder)
{
var searchLocalSystem = document.getElementById("checkSearchLocalSystem");
return searchLocalSystem && searchLocalSystem.checked ? nsMsgSearchScope.offlineMail : folder.server.searchScope;
let searchOnline = document.getElementById("checkSearchOnline");
if (searchOnline && searchOnline.checked)
{
gSearchOnline = true;
return folder.server.searchScope;
}
gSearchOnline = false;
// We are going to search offline. The proper search scope may depend on
// whether we have the body and/or junk available or not.
let localType;
try
{
localType = folder.server.localStoreType;
}
catch (e) {} // On error, we'll just assume the default mailbox type
let hasBody = folder.getFlag(Components.interfaces.nsMsgFolderFlags.Offline);
let nsMsgSearchScope = Components.interfaces.nsMsgSearchScope;
switch (localType)
{
case "news":
// News has four offline scopes, depending on whether junk and body
// are available.
let hasJunk =
folder.getInheritedStringProperty("dobayes.mailnews@mozilla.org#junk")
== "true";
if (hasJunk && hasBody)
return nsMsgSearchScope.localNewsJunkBody;
if (hasJunk) // and no body
return nsMsgSearchScope.localNewsJunk;
if (hasBody) // and no junk
return nsMsgSearchScope.localNewsBody;
// We don't have offline message bodies or junk processing.
return nsMsgSearchScope.localNews;
case "imap":
// Junk is always enabled for imap, so the offline scope only depends on
// whether the body is available.
if (!hasBody)
return nsMsgSearchScope.onlineManual;
// fall through to default
default:
return nsMsgSearchScope.offlineMail;
}
}
var nsMsgViewSortType = Components.interfaces.nsMsgViewSortType;
@ -588,6 +667,7 @@ function saveAsVirtualFolder()
{folder: window.arguments[0].folder,
searchTerms: toXPCOMArray(getSearchTerms(),
Components.interfaces.nsISupportsArray),
searchFolderURIs: searchFolderURIs});
searchFolderURIs: searchFolderURIs,
searchOnline: document.getElementById("checkSearchOnline").checked});
}

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

@ -123,6 +123,12 @@
<spacer flex="10"/>
<button label="&resetButton.label;" oncommand="onResetSearch(event);" accesskey="&resetButton.accesskey;"/>
</hbox>
<hbox align="center">
<checkbox id="checkSearchOnline"
label="&searchOnline.label;"
accesskey="&searchOnline.accesskey;"
oncommand="updateSearchLocalSystem();"/>
</hbox>
</vbox>
<hbox flex="1">

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

@ -207,8 +207,7 @@ let gFolderTreeView = {
* @param event the double-click event
*/
onDoubleClick: function ftv_onDoubleClick(aEvent) {
if (pref.getBoolPref("mailnews.reuse_thread_window2") ||
aEvent.button != 0 || aEvent.originalTarget.localName == "twisty" ||
if (aEvent.button != 0 || aEvent.originalTarget.localName == "twisty" ||
aEvent.originalTarget.localName == "slider" ||
aEvent.originalTarget.localName == "scrollbarbutton")
return;
@ -1411,7 +1410,10 @@ ftvItem.prototype = {
},
command: function fti_command() {
MsgOpenNewWindowForFolder(this._folder.URI, -1 /* key */);
let pref = Components.classes["@mozilla.org/preferences-service;1"]
.getService(Components.interfaces.nsIPrefBranch);
if (!pref.getBoolPref("mailnews.reuse_thread_window2"))
MsgOpenNewWindowForFolder(this._folder.URI, -1 /* key */);
},
_children: null,

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

@ -233,6 +233,8 @@ var DefaultController =
case "cmd_fullZoomEnlarge":
case "cmd_fullZoomReset":
case "cmd_fullZoomToggle":
case "cmd_viewAllHeader":
case "cmd_viewNormalHeader":
return true;
case "cmd_downloadFlagged":
case "cmd_downloadSelected":
@ -347,6 +349,8 @@ var DefaultController =
return gFolderDisplay.getCommandStatus(nsMsgViewCommandType.cmdRequiringMsgBody);
return false;
case "cmd_printSetup":
case "cmd_viewAllHeader":
case "cmd_viewNormalHeader":
return true;
case "cmd_markAsFlagged":
case "button_file":
@ -359,12 +363,14 @@ var DefaultController =
Components.interfaces.nsMsgFolderFlags.Archive, true);
case "cmd_markAsJunk":
case "cmd_markAsNotJunk":
// can't do news on junk yet.
return (GetNumSelectedMessages() > 0 && !gFolderDisplay.selectedMessageIsNews);
return gFolderDisplay.getCommandStatus(nsMsgViewCommandType.junk);
case "cmd_recalculateJunkScore":
if (GetNumSelectedMessages() > 0)
return gFolderDisplay.getCommandStatus(nsMsgViewCommandType.runJunkControls);
return false;
// We're going to take a conservative position here, because we really
// don't want people running junk controls on folders that are not
// enabled for junk. The junk type picks up possible dummy message headers,
// while the runJunkControls will prevent running on XF virtual folders.
return gFolderDisplay.getCommandStatus(nsMsgViewCommandType.junk) &&
gFolderDisplay.getCommandStatus(nsMsgViewCommandType.runJunkControls);
case "cmd_displayMsgFilters":
let mgr = Components.classes["@mozilla.org/messenger/account-manager;1"]
.getService(Components.interfaces.nsIMsgAccountManager);
@ -744,6 +750,12 @@ var DefaultController =
case "cmd_markAsFlagged":
MsgMarkAsFlagged();
return;
case "cmd_viewAllHeader":
MsgViewAllHeaders();
return;
case "cmd_viewNormalHeader":
MsgViewNormalHeaders();
return;
case "cmd_markAsJunk":
JunkSelectedMessages(true);
return;

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

@ -393,6 +393,11 @@
while (index < numAddresses && index < aNumAddressesToShow)
{
var newAddressNode = document.createElement("mail-emailaddress");
// Stash the headerName somewhere that AddExtraAddressProcessing
// will be able to find it.
newAddressNode.setAttribute("headerName", this.headerName);
if (index)
{
var textNode = document.createElement("text");

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

@ -406,31 +406,13 @@ function initMoveToFolderAgainMenu(aMenuItem)
function InitViewHeadersMenu()
{
var headerchoice = 1;
try
{
headerchoice = pref.getIntPref("mail.show_headers");
}
catch (ex)
{
dump("failed to get the header pref\n");
}
var id = null;
switch (headerchoice)
{
case 2:
id = "viewallheaders";
break;
case 1:
default:
id = "viewnormalheaders";
break;
}
var menuitem = document.getElementById(id);
if (menuitem)
menuitem.setAttribute("checked", "true");
const nsMimeHeaderDisplayTypes = Components.interfaces.nsMimeHeaderDisplayTypes;
var headerchoice = pref.getIntPref("mail.show_headers");
document.getElementById("cmd_viewAllHeader")
.setAttribute("checked", headerchoice == nsMimeHeaderDisplayTypes.AllHeaders);
document.getElementById("cmd_viewNormalHeader")
.setAttribute("checked", headerchoice == nsMimeHeaderDisplayTypes.NormalHeaders);
document.commandDispatcher.updateCommands("create-menu-mark");
}
function InitViewBodyMenu()
@ -2450,7 +2432,7 @@ function UpdateJunkButton()
return;
let junkScore = hdr.getStringProperty("junkscore");
let hideJunk = (junkScore == Components.interfaces.nsIJunkMailPlugin.IS_SPAM_SCORE);
if (gFolderDisplay.selectedMessageIsNews)
if (!gFolderDisplay.getCommandStatus(nsMsgViewCommandType.junk))
hideJunk = true;
getCurrentMsgHdrButtonBox().getButton('hdrJunkButton').disabled = hideJunk;

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

@ -302,6 +302,8 @@
<command id="cmd_markAsJunk" oncommand="goDoCommand('cmd_markAsJunk'); event.stopPropagation()" disabled="true"/>
<command id="cmd_markAsNotJunk" oncommand="goDoCommand('cmd_markAsNotJunk'); event.stopPropagation()" disabled="true"/>
<command id="cmd_recalculateJunkScore" oncommand="goDoCommand('cmd_recalculateJunkScore');" disabled="true"/>
<command id="cmd_viewAllHeader" oncommand="goDoCommand('cmd_viewAllHeader');" disabled="true"/>
<command id="cmd_viewNormalHeader" oncommand="goDoCommand('cmd_viewNormalHeader');" disabled="true"/>
</commandset>
<commandset id="mailToolsMenuItems"
@ -1119,13 +1121,13 @@
name="viewheadergroup"
label="&headersAllCmd.label;"
accesskey="&headersAllCmd.accesskey;"
oncommand="MsgViewAllHeaders();"/>
command="cmd_viewAllHeader"/>
<menuitem id="viewnormalheaders"
type="radio"
name="viewheadergroup"
label="&headersNormalCmd.label;"
accesskey="&headersNormalCmd.accesskey;"
oncommand="MsgViewNormalHeaders();"/>
command="cmd_viewNormalHeader"/>
</menupopup>
</menu>
<menu id="viewBodyMenu" accesskey="&bodyMenu.accesskey;" label="&bodyMenu.label;">

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

@ -208,8 +208,8 @@ MessageDisplayWidget.prototype = {
let selectedCount = this.folderDisplay.selectedCount;
if (selectedCount == 0) {
// davida, put your folder summary stuff here.
this.clearDisplay();
loadStartPage();
this.singleMessageDisplay = true;
return true;
}

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

@ -763,6 +763,8 @@ var MessageWindowController =
case "cmd_fullZoomEnlarge":
case "cmd_fullZoomReset":
case "cmd_fullZoomToggle":
case "cmd_viewAllHeader":
case "cmd_viewNormalHeader":
return true;
case "cmd_synchronizeOffline":
case "cmd_downloadFlagged":
@ -799,9 +801,10 @@ var MessageWindowController =
// fall through
case "cmd_markAsJunk":
case "cmd_markAsNotJunk":
return gFolderDisplay.getCommandStatus(nsMsgViewCommandType.junk);
case "cmd_recalculateJunkScore":
// can't do junk on news yet
return (!gFolderDisplay.view.isNewsFolder);
return gFolderDisplay.selectedMessage &&
gFolderDisplay.getCommandStatus(nsMsgViewCommandType.runJunkControls);
case "button_archive":
var folder = gFolderDisplay.displayedFolder;
return folder &&
@ -837,6 +840,8 @@ var MessageWindowController =
case "cmd_markAllRead":
case "cmd_markThreadAsRead":
case "cmd_markReadByDate":
case "cmd_viewAllHeader":
case "cmd_viewNormalHeader":
return(true);
case "cmd_markAsFlagged":
case "button_file":
@ -1032,6 +1037,12 @@ var MessageWindowController =
case "cmd_markReadByDate":
MsgMarkReadByDate();
return;
case "cmd_viewAllHeader":
MsgViewAllHeaders();
return;
case "cmd_viewNormalHeader":
MsgViewNormalHeaders();
return;
case "cmd_markAsFlagged":
MsgMarkAsFlagged();
return;

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

@ -183,6 +183,12 @@ function createHeaderEntry(prefix, headerListInfo)
this.outputFunction = headerListInfo.outputFunction;
else
this.outputFunction = updateHeaderValue;
// stash this so that the <mail-multi-emailheaderfield/> binding can
// later attach it to any <mail-emailaddress> tags it creates for later
// extraction and use by AddExtraAddressProcessing.
this.enclosingBox.headerName = headerListInfo.name;
}
function initializeHeaderViewTables()
@ -1023,10 +1029,21 @@ function AddExtraAddressProcessing(emailAddress, documentNode)
if (!gShowCondensedEmailAddresses)
return;
// If this address is one of the user's identities...
var displayName;
var identity = getBestIdentity(accountManager.allIdentities);
if (emailAddress == identity.email) {
displayName = gMessengerBundle.getString("headerFieldYou");
// ...pick a localized version of the word "You" appropriate to this
// specific header; fall back to the version used by the "to" header
// if nothing else is available.
let headerName = documentNode.getAttribute("headerName");
try {
displayName = gMessengerBundle.getString("header" + headerName +
"FieldYou");
} catch (ex) {
displayName = gMessengerBundle.getString("headertoFieldYou");
}
}
else
{

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

@ -36,11 +36,11 @@
* ***** END LICENSE BLOCK ***** */
.tabmail-tabs {
-moz-binding: url("chrome://messenger/skin/tabmailBindings.xml#tabmail-tabs");
-moz-binding: url("chrome://messenger/content/tabmail.xml#tabmail-tabs");
}
.tabmail-tab {
-moz-binding: url("chrome://messenger/skin/tabmailBindings.xml#tabmail-tab");
-moz-binding: url("chrome://messenger/content/tabmail.xml#tabmail-tab");
}
.tabmail-arrowscrollbox {

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

@ -22,6 +22,7 @@
- Contributor(s):
- Scott MacGregor <mscott@mozilla.org>
- Andrew Sutherland <asutherland@asutherland.org>
- Magnus Melin <mkmelin+mozilla@iki.fi>
-
- Alternatively, the contents of this file may be used under the terms of
- either the GNU General Public License Version 2 or later (the "GPL"), or
@ -1067,16 +1068,21 @@
</method>
</implementation>
</binding>
<binding id="tabmail-tab" display="xul:box"
<binding id="tabmail-tab" display="xul:box"
extends="chrome://global/content/bindings/tabbox.xml#tab">
<content chromedir="&locale.dir;"
closetabtext="&closeTab.label;">
<xul:hbox class="tab-middle box-inherit" xbl:inherits="align,dir,pack,orient,selected" flex="1">
<xul:image class="tab-icon" xbl:inherits="validate,src=image"/>
<xul:label class="tab-text" xbl:inherits="value=label,accesskey,crop,disabled" flex="1"/>
<xul:hbox class="tab-image-left" xbl:inherits="selected"/>
<xul:hbox class="tab-image-middle box-inherit" align="center"
xbl:inherits="dir,pack,orient,selected" flex="1">
<xul:image class="tab-icon-image" xbl:inherits="validate,src=image"/>
<xul:label class="tab-text"
xbl:inherits="value=label,accesskey,crop,disabled"
crop="right" flex="1"/>
</xul:hbox>
<xul:toolbarbutton anonid="close-button" tabindex="-1" class="tab-close-button"/>
<xul:toolbarbutton anonid="close-button" class="tab-close-button" tabindex="-1"/>
<xul:hbox class="tab-image-right" xbl:inherits="selected"/>
</content>
<implementation>
@ -1190,27 +1196,49 @@
<binding id="tabmail-tabs"
extends="chrome://global/content/bindings/tabbox.xml#tabs">
<content>
<xul:arrowscrollbox anonid="arrowscrollbox" class="tabmail-arrowscrollbox" flex="1"
xbl:inherits="smoothscroll" orient="horizontal" style="min-width: 1px;">
<children includes="tab"/>
</xul:arrowscrollbox>
<children/>
<xul:stack align="center" pack="end" class="tabs-alltabs-stack">
<xul:hbox flex="1" class="tabs-alltabs-box" anonid="alltabs-box"/>
<xul:hbox flex="1" class="tabs-alltabs-box-animate"
anonid="alltabs-box-animate"/>
<xul:toolbarbutton class="tabs-alltabs-button" type="menu"
anonid="alltabs-button"
tooltipstring="&listAllTabs.label;">
<xul:menupopup class="tabs-alltabs-popup"
anonid="alltabs-popup"
position="after_end"/>
</xul:toolbarbutton>
<xul:stack flex="1" class="tabs-stack">
<xul:vbox>
<xul:spacer flex="1"/>
<xul:hbox class="tabs-bottom" align="center"/>
</xul:vbox>
<xul:vbox>
<xul:hbox>
<xul:stack>
<xul:spacer class="tabs-left"/>
</xul:stack>
<xul:arrowscrollbox class="tabmail-arrowscrollbox"
anonid="arrowscrollbox"
orient="horizontal"
flex="1"
style="min-width: 1px;"
chromedir="&locale.dir;">
<children includes="tab"/>
</xul:arrowscrollbox>
<children/>
<xul:stack align="center" pack="end" chromedir="&locale.dir;">
<xul:hbox class="tabs-alltabs-box" anonid="alltabs-box" flex="1"/>
<xul:hbox class="tabs-alltabs-box-animate"
anonid="alltabs-box-animate"
flex="1"/>
<xul:toolbarbutton class="tabs-alltabs-button"
anonid="alltabs-button"
type="menu"
tooltipstring="&listAllTabs.label;">
<xul:menupopup class="tabs-alltabs-popup"
anonid="alltabs-popup" position="after_end"/>
</xul:toolbarbutton>
</xul:stack>
<xul:hbox class="tabs-closebutton-box"
anonid="tabstrip-closebutton"
align="center" pack="end">
<xul:toolbarbutton class="close-button tabs-closebutton"/>
</xul:hbox>
</xul:hbox>
<xul:spacer class="tabs-bottom-spacer"/>
</xul:vbox>
</xul:stack>
<xul:hbox class="tabs-closebutton-box" align="center" pack="end" anonid="tabstrip-closebutton">
<xul:toolbarbutton class="close-button tabs-closebutton"/>
</xul:hbox>
</content>
<implementation implements="nsITimerCallback, nsIDOMEventListener">
<constructor>
<![CDATA[

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

@ -93,7 +93,7 @@ var gEditCard;
var gOnSaveListeners = new Array();
var gOkCallback = null;
var gHideABPicker = false;
var originalPhotoURI = "";
var gOriginalPhotoURI = "";
function OnLoadNewCard()
{
@ -279,15 +279,6 @@ function OnLoadEditCard()
if (directory.readOnly)
{
// Disable the photo field and buttons
document.getElementById("generic").disabled = true;
document.getElementById("GenericPhotoList").disabled = true;
document.getElementById("file").disabled = true;
document.getElementById("web").disabled = true;
document.getElementById("PhotoURI").readOnly = true;
document.getElementById("PhotoURI").emptyText = "";
document.getElementById("BrowsePhoto").disabled = true;
document.getElementById("UpdatePhoto").disabled = true;
// Set all the editable vcard fields to read only
for (var i = kVcardFields.length; i-- > 0; )
document.getElementById(kVcardFields[i][0]).readOnly = true;
@ -297,6 +288,14 @@ function OnLoadEditCard()
document.getElementById("BirthYear").readOnly = true;
document.getElementById("Age").readOnly = true;
// the photo field and buttons
document.getElementById("PhotoType").disabled = true;
document.getElementById("GenericPhotoList").disabled = true;
document.getElementById("PhotoURI").disabled = true;
document.getElementById("PhotoURI").emptyText = "";
document.getElementById("BrowsePhoto").disabled = true;
document.getElementById("UpdatePhoto").disabled = true;
// And the phonetic fields
document.getElementById(kPhoneticFields[0]).readOnly = true;
document.getElementById(kPhoneticFields[3]).readOnly = true;
@ -487,34 +486,32 @@ function GetCardValues(cardproperty, doc)
// Store the original photo URI and update the photo
// Select the type if there is a valid value stored for that type, otherwise
// select the generic photo
var type = cardproperty.getProperty("PhotoType", "");
document.getElementById("PhotoType").selectedItem =
document.getElementById(type ? type : "generic");
if (type == "file") {
originalPhotoURI = getPhotoURI(cardproperty.getProperty("PhotoName", ""));
var file = Components.classes["@mozilla.org/network/io-service;1"]
.getService(Components.interfaces.nsIIOService)
.newURI(originalPhotoURI, null, null)
.QueryInterface(Components.interfaces.nsIFileURL)
.file;
if (file) {
document.getElementById("PhotoFile").file = file;
updatePhoto("file");
}
else
gOriginalPhotoURI = cardproperty.getProperty("PhotoURI", "");
switch (cardproperty.getProperty("PhotoType", "")) {
case "file":
try {
var file = Components.classes["@mozilla.org/network/io-service;1"]
.getService(Components.interfaces.nsIIOService)
.newURI(gOriginalPhotoURI, null, null)
.QueryInterface(Components.interfaces.nsIFileURL)
.file;
} catch (e) {}
if (file) {
document.getElementById("PhotoFile").file = file;
updatePhoto("file");
}
else
updatePhoto("generic");
break;
case "web":
document.getElementById("PhotoURI").value = gOriginalPhotoURI;
updatePhoto("web");
break;
default:
if (gOriginalPhotoURI)
document.getElementById("GenericPhotoList").value = gOriginalPhotoURI;
updatePhoto("generic");
}
else if (type == "web") {
originalPhotoURI = getPhotoURI(cardproperty.getProperty("PhotoName", ""));
document.getElementById("PhotoURI").value = originalPhotoURI;
updatePhoto("web");
}
else {
originalPhotoURI = cardproperty.getProperty("PhotoURI", "");
if (originalPhotoURI)
document.getElementById("GenericPhotoList").value = originalPhotoURI;
updatePhoto("generic");
}
}
// when the ab card dialog is being loaded to show a vCard,
@ -572,31 +569,36 @@ function CheckAndSetCardValues(cardproperty, doc, check)
}
catch (ex) {}
var type = document.getElementById("PhotoType").selectedItem.id;
var photoURI = originalPhotoURI;
var type = document.getElementById("PhotoType").value;
var photoURI = gOriginalPhotoURI;
if (type == "file" && document.getElementById("PhotoFile").file)
photoURI = "file://" + document.getElementById("PhotoFile").file.path;
photoURI = Components.classes["@mozilla.org/network/io-service;1"]
.getService(Components.interfaces.nsIIOService)
.newFileURI(document.getElementById("PhotoFile").file)
.spec;
else if (type == "web" && document.getElementById("PhotoURI").value)
photoURI = document.getElementById("PhotoURI").value;
else {
type = "generic";
photoURI = document.getElementById("GenericPhotoList").value;
}
if (photoURI != originalPhotoURI) {
cardproperty.setProperty("PhotoType", type);
if (photoURI != gOriginalPhotoURI) {
// Store the original URI
cardproperty.setProperty("PhotoURI", photoURI);
// Remove the original, if any
removePhoto(cardproperty.getProperty("PhotoName", null));
// Save the photo if it isn't one of the generic photos
if (type != "generic") {
cardproperty.setProperty("PhotoType", "file");
if (type == "generic") {
// Remove the original, if any
removePhoto(cardproperty.getProperty("PhotoName", null));
} else {
// Save the new file and store its URI as PhotoName
var file = savePhoto(photoURI);
if (file)
if (file) {
// Remove the original, if any
removePhoto(cardproperty.getProperty("PhotoName", null));
cardproperty.setProperty("PhotoName", file.leafName);
}
}
else
cardproperty.setProperty("PhotoType", "generic");
}
return true;
}
@ -905,25 +907,28 @@ function modifyDatepicker(aDatepicker) {
* selected type.
*/
function updatePhoto(aType) {
if (aType) {
if (aType)
// Select the type's radio button
document.getElementById("PhotoType").selectedItem =
document.getElementById(aType);
}
document.getElementById("PhotoType").value = aType;
else
aType = document.getElementById("PhotoType").selectedItem.id;
aType = document.getElementById("PhotoType").value;
var value;
if (aType == "file") {
var file = document.getElementById("PhotoFile").file;
value = file ? "file://" + file.path : "";
switch (aType) {
case "file":
var file = document.getElementById("PhotoFile").file;
value = file ? Components.classes["@mozilla.org/network/io-service;1"]
.getService(Components.interfaces.nsIIOService)
.newFileURI(file)
.spec : "";
break;
case "web":
value = document.getElementById("PhotoURI").value;
break;
default:
value = document.getElementById("GenericPhotoList").value;
}
else if (aType == "web")
value = document.getElementById("PhotoURI").value;
else
value = document.getElementById("GenericPhotoList").value;
document.getElementById("photo").setAttribute("src", value ? value
: defaultPhotoURI);
document.getElementById("photo").setAttribute("src", value || defaultPhotoURI);
}
/**
@ -941,17 +946,10 @@ function removePhoto(aName) {
// Get the photo (throws an exception for invalid names)
try {
file.append(aName);
file.remove(false);
return true;
}
catch (e) {
return false;
}
if (file.exists()) {
try {
file.remove(false);
return true;
}
catch (e) {}
}
catch (e) {}
return false;
}
@ -969,8 +967,8 @@ function browsePhoto() {
fp.init(window, gAddressBookBundle.getString("browsePhoto"), nsIFilePicker.modeOpen);
// Add All Files & Image Files filters and select the latter
fp.appendFilters(nsIFilePicker.filterAll | nsIFilePicker.filterImages);
fp.filterIndex = 1;
fp.appendFilters(nsIFilePicker.filterImages);
fp.appendFilters(nsIFilePicker.filterAll);
if (fp.show() == nsIFilePicker.returnOK) {
document.getElementById("PhotoFile").file = fp.file;

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

@ -1024,7 +1024,7 @@ function savePhoto(aUri) {
var istream = channel.open();
// Get the photo file
file.append(makePhotoFilename(file.path, findPhotoExt(aUri, channel)));
file = makePhotoFile(file, findPhotoExt(channel));
return saveStreamToFile(istream, file);
}
@ -1041,27 +1041,17 @@ function savePhoto(aUri) {
*
* @return The extension of the file, if any, including the period.
*/
function findPhotoExt(aUri, aChannel) {
if (aChannel) {
try {
aChannel.QueryInterface(Components.interfaces.nsIHttpChannel);
var header = aChannel.getResponseHeader("Content-Type");
var type = header ? header.split(";")[0] : "";
switch (type.toLowerCase()) {
case "image/png":
return ".png";
case "image/jpeg":
return ".jpg";
case "image/gif":
return ".gif";
}
} catch (e) {}
}
var index = aUri ? aUri.lastIndexOf(".") : -1;
if (index == -1)
return "";
return aUri.substring(index);
function findPhotoExt(aChannel) {
var mimeSvc = Components.classes["@mozilla.org/mime;1"]
.getService(Components.interfaces.nsIMIMEService);
var ext = "";
var uri = aChannel.URI;
if (uri instanceof Components.interfaces.nsIURL)
ext = uri.fileExtension;
try {
return mimeSvc.getPrimaryExtension(aChannel.contentType, ext);
} catch (e) {}
return ext;
}
/**
@ -1072,15 +1062,13 @@ function findPhotoExt(aUri, aChannel) {
*
* @return A unique filename in the given path.
*/
function makePhotoFilename(aPath, aExtension) {
function makePhotoFile(aDir, aExtension) {
var filename, newFile;
// Find a random filename for the photo that doesn't exist yet
do {
filename = new String(Math.random()).replace("0.", "") + aExtension;
newFile = Components.classes["@mozilla.org/file/local;1"]
.createInstance(Components.interfaces.nsILocalFile);
newFile.initWithPath(aPath);
filename = new String(Math.random()).replace("0.", "") + "." + aExtension;
newFile = aDir.clone();
newFile.append(filename);
} while (newFile.exists());
return filename;
return newFile;
}

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

@ -1007,7 +1007,7 @@ nsDogbertProfileMigrator::ProcessPrefsCallback(const char* oldProfilePathStr, co
}
#endif /* HAVE_MOVEMAIL */
else {
NS_ASSERTION(0,"failure, didn't recognize your mail server type.\n");
NS_ERROR("failure, didn't recognize your mail server type.");
return NS_ERROR_UNEXPECTED;
}
@ -1134,7 +1134,7 @@ nsDogbertProfileMigrator::ProcessPrefsCallback(const char* oldProfilePathStr, co
}
#endif /* HAVE_MOVEMAIL */
else {
NS_ASSERTION(0, "unknown mail server type!");
NS_ERROR("unknown mail server type!");
return NS_ERROR_FAILURE;
}

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

@ -3,6 +3,8 @@
<!ENTITY searchHeading.accesskey "h">
<!ENTITY searchSubfolders.label "Search subfolders">
<!ENTITY searchSubfolders.accesskey "e">
<!ENTITY searchOnline.label "Search online">
<!ENTITY searchOnline.accesskey "l">
<!ENTITY resetButton.label "Clear">
<!ENTITY resetButton.accesskey "C">
<!ENTITY openButton.label "Open">

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

@ -1,3 +1,4 @@
<!ENTITY identityDialog.style "width: 67ch;">
<!ENTITY identityTitle.label "Identity Settings">
<!ENTITY identityListDesc.label "Configure the settings for this identity:">

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

@ -486,9 +486,27 @@ fileEmptyTitle = File Empty
#LOCALIZATION NOTE(fileEmptyMsg): %S is the filename
fileEmptyMsg = The file %S is empty.
# second person direct object pronoun; used in the collapsed header view if
# the user is in the To or Cc field of a message
headerFieldYou=You
# LOCALIZATION NOTE (headertoFieldYou): second person prepositional object
# pronoun used in the "to" header of the message header pane. This is also
# used for the fallback case if a header-specific localization is not
# available.
headertoFieldYou=You
# LOCALIZATION NOTE (headerfromFieldYou): second person prepositional object
# pronoun used in the "from" header of the message header pane.
headerfromFieldYou=You
# LOCALIZATION NOTE (headerreply-toFieldYou): second person prepositional
# object pronoun used in the "reply-to" header of the message header pane.
headerreply-toFieldYou=You
# LOCALIZATION NOTE (headerccFieldYou): second person prepositional object
# pronoun used in the "cc" header of the message header pane.
headerccFieldYou=You
# LOCALIZATION NOTE (headerbccFieldYou): second person prepositional object
# pronoun used in the "bcc" header of the message header pane.
headerbccFieldYou=You
# Shown when content tabs are being loaded.
loadingTab=Loading…

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

@ -1,6 +1,6 @@
<!ENTITY prefWindow.titleWin "Options">
<!ENTITY prefWindow.titleGNOME "&brandShortName; Preferences">
<!ENTITY prefWindow.styleWindows "width: 44em; min-height: 38.5em;">
<!ENTITY prefWindow.styleWindows "width: 48em; min-height: 38.5em;">
<!ENTITY prefWindow.styleMac "width: 47em;">
<!ENTITY prefWindow.styleGNOME "width: 47em; min-height: 38em;">

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

@ -0,0 +1,13 @@
<html>
<head>
<title>Cookie Test</title>
<script type="text/javascript">
document.cookie = "name=CookieTest";
</script>
</head>
<body bgcolor="#FFFFFF">
<div align="center">
<h1>Cookie Test</h1>
</div>
</body>
</html>

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

@ -0,0 +1,13 @@
<html>
<head>
<title>Cookie Test 2</title>
</head>
<body bgcolor="#FFFFFF">
<script type="text/javascript">
var theCookie = document.cookie;
</script>
<div align="center">
<h1>Cookie Test Result</h1>
</div>
</body>
</html>

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

@ -0,0 +1,114 @@
/* ***** BEGIN LICENSE BLOCK *****
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
*
* The contents of this file are subject to the Mozilla Public License Version
* 1.1 (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
* http://www.mozilla.org/MPL/
*
* Software distributed under the License is distributed on an "AS IS" basis,
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
* for the specific language governing rights and limitations under the
* License.
*
* The Original Code is Thunderbird Mail Client.
*
* The Initial Developer of the Original Code is
* Mozilla Messaging, Inc.
* Portions created by the Initial Developer are Copyright (C) 2009
* the Initial Developer. All Rights Reserved.
*
* Contributor(s):
* Mark Banner <bugzilla@standard8.pus.com>
*
* Alternatively, the contents of this file may be used under the terms of
* either the GNU General Public License Version 2 or later (the "GPL"), or
* the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
* in which case the provisions of the GPL or the LGPL are applicable instead
* of those above. If you wish to allow use of your version of this file only
* under the terms of either the GPL or the LGPL, and not to allow others to
* use your version of this file under the terms of the MPL, indicate your
* decision by deleting the provisions above and replace them with the notice
* and other provisions required by the GPL or the LGPL. If you do not delete
* the provisions above, a recipient may use your version of this file under
* the terms of any one of the MPL, the GPL or the LGPL.
*
* ***** END LICENSE BLOCK ***** */
/**
* Test file to check that cookies are correctly enabled in Thunderbird.
*
* XXX: Still need to check remote content in messages.
* XXX: Swap cookie checks when bug 501925 lands.
*/
var MODULE_NAME = 'test-cookies';
var RELATIVE_ROOT = "../shared-modules";
var MODULE_REQUIRES = ['window-helpers'];
var controller = {};
Components.utils.import('resource://mozmill/modules/controller.js', controller);
var mozmill = {}; Components.utils.import('resource://mozmill/modules/mozmill.js', mozmill);
var elementslib = {}; Components.utils.import('resource://mozmill/modules/elementslib.js', elementslib);
// The main controller and an easy alias.
var mainController = null;
var mc;
// The windowHelper module.
var windowHelper;
var newTab = null;
// RELATIVE_ROOT messes with the collector, so we have to bring the path back
// so we get the right path for the resources.
var url = collector.addHttpResource('../cookies/html', 'cookies');
function setupModule(module) {
windowHelper = collector.getModule('window-helpers');
mc = mainController = windowHelper.wait_for_existing_window("mail:3pane");
windowHelper.augment_controller(mc);
}
/**
* Test deleting junk messages with no messages marked as junk.
*/
function test_load_cookie_page() {
newTab = mc.tabmail.openTab("contentTab",
{contentPage: url + "cookietest1.html"});
if (!newTab)
throw new Error("Expected new tab info to be returned from openTab");
// XXX When bug 508999 is fixed, remove the sleep and use the waitForEval
// instead.
// controller.waitForEval("subject.busy == false", 1000, 100, newTab);
controller.sleep(1000);
}
function test_load_cookie_result_page() {
newTab = mc.tabmail.openTab("contentTab",
{contentPage: url + "cookietest2.html"});
if (!newTab)
throw new Error("Expected new tab info to be returned from openTab");
// XXX When bug 508999 is fixed, remove the sleep and use the waitForEval
// instead.
// controller.waitForEval("subject.busy == false", 1000, 100, newTab);
controller.sleep(1000);
if (mc.window.content.document.title != "Cookie Test 2")
throw new Error("The cookie test 2 page is not the selected tab or not content-primary");
let cookie = mc.window.content.wrappedJSObject.theCookie;
dump("Cookie is: " + cookie + "\n");
if (!cookie)
throw new Error("Document has no cookie :-(");
if (cookie != "name=CookieTest")
throw new Error("Cookie set incorrectly, expected: name=CookieTest, got: " +cookie + "\n");
}

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

@ -0,0 +1,126 @@
/* ***** BEGIN LICENSE BLOCK *****
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
*
* The contents of this file are subject to the Mozilla Public License Version
* 1.1 (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
* http://www.mozilla.org/MPL/
*
* Software distributed under the License is distributed on an "AS IS" basis,
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
* for the specific language governing rights and limitations under the
* License.
*
* The Original Code is Thunderbird Mail Client.
*
* The Initial Developer of the Original Code is
* Mozilla Messaging, Inc.
* Portions created by the Initial Developer are Copyright (C) 2009
* the Initial Developer. All Rights Reserved.
*
* Contributor(s):
* Andrew Sutherland <asutherland@asutherland.org>
*
* Alternatively, the contents of this file may be used under the terms of
* either the GNU General Public License Version 2 or later (the "GPL"), or
* the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
* in which case the provisions of the GPL or the LGPL are applicable instead
* of those above. If you wish to allow use of your version of this file only
* under the terms of either the GPL or the LGPL, and not to allow others to
* use your version of this file under the terms of the MPL, indicate your
* decision by deleting the provisions above and replace them with the notice
* and other provisions required by the GPL or the LGPL. If you do not delete
* the provisions above, a recipient may use your version of this file under
* the terms of any one of the MPL, the GPL or the LGPL.
*
* ***** END LICENSE BLOCK ***** */
var MODULE_NAME = 'test-quick-search';
var RELATIVE_ROOT = '../shared-modules';
var MODULE_REQUIRES = ['folder-display-helpers', 'window-helpers'];
var folder;
var setFoo, setBar;
function setupModule(module) {
let fdh = collector.getModule('folder-display-helpers');
fdh.installInto(module);
let wh = collector.getModule('window-helpers');
wh.installInto(module);
folder = create_folder("QuickSearch");
[setFoo, setBar] =
make_new_sets_in_folder(folder, [{subject: "foo", count: 1},
{subject: "bar", count: 1}]);
}
/**
*
*/
function test_save_quick_search() {
be_in_folder(folder);
// - Type something in the quick search box.
mc.type(mc.eid("searchInput"), "foo");
mc.keypress(mc.eid("searchInput"), "VK_RETURN", {});
wait_for_all_messages_to_load();
// - Click the "Save Search as a Folder" button
// This will create a virtual folder properties dialog...
// (label: "New Saved Search Folder", source: virtualFolderProperties.xul
// no windowtype, id: "virtualFolderPropertiesDialog")
plan_for_modal_dialog("mailnews:virtualFolderProperties",
subtest_save_search);
mc.click(mc.eid("quickSearchSaveAsVirtualFolder"));
wait_for_modal_dialog("mailnews:virtualFolderProperties");
}
/**
* Save the search, making sure that the "subject OR from" constraints are
* there.
*/
function subtest_save_search(savc) {
// - make sure our constraint propagated
// this should be an "OR" constraint
savc.assertValue(savc.eid("booleanAndGroup"), "or");
// first constraint is on "Subject"=0 and should be "foo"
let searchAttr0 = savc.eid("searchAttr0");
savc.assertNode(searchAttr0);
savc.assertValue(searchAttr0, "0");
let searchVal0 = savc.aid("searchVal0", {crazyDeck: 0});
savc.assertNode(searchVal0);
savc.assertValue(searchVal0, "foo");
// second constraint is on "From"=1 and should be "foo" as well
let searchAttr1 = savc.eid("searchAttr1");
savc.assertNode(searchAttr1);
savc.assertValue(searchAttr1, "1");
let searchVal1 = savc.aid("searchVal1", {crazyDeck: 0});
savc.assertNode(searchVal1);
savc.assertValue(searchVal1, "foo");
// - Make sure the name mangling is as expected
savc.assertValue(savc.eid("name"), "QuickSearch-foo");
// - save it!
// this will close the dialog, which wait_for_modal_dialog is making sure
// happens.
savc.window.onOK();
}
/**
* Make sure the folder showed up with the right name, and that displaying it
* has the right contents.
*/
function test_verify_saved_search() {
let savedFolder = folder.findSubFolder("QuickSearch-foo");
if (savedFolder == null)
throw new Error("Saved folder did not show up.");
be_in_folder(savedFolder);
assert_messages_in_view(setFoo);
}

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

@ -1,5 +1,6 @@
folder-display
junk-commands
search-window
cookies
content-policy
content-tabs

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

@ -130,7 +130,10 @@ class ThunderTestProfile(mozrunner.ThunderbirdProfile):
'mail.smtpserver.smtp1.username' : "tinderbox",
'mail.smtpservers' : "smtp1",
'mail.startup.enabledMailCheckOnce' : True,
# Don't load what's new or the remote start page - keep everything local
# under our control.
'mailnews.start_page_override.mstone' : "ignore",
'mailnews.start_page.url': "about:blank",
}
def __init__(self, default_profile=None, profile=None, create_new=True,

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

@ -30,7 +30,6 @@ classic.jar:
skin/classic/messenger/icons/exclude-selected.png (mail/icons/exclude-selected.png)
skin/classic/messenger/dialogs.css (mail/dialogs.css)
skin/classic/messenger/newmailalert.css (mail/newmailalert.css)
* skin/classic/messenger/tabmailBindings.xml (mail/tabmailBindings.xml)
skin/classic/messenger/tabmail.css (mail/tabmail.css)
skin/classic/messenger/editContactOverlay.css (mail/editContactOverlay.css)
skin/classic/messenger/starred48.png (mail/starred48.png)

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

@ -67,27 +67,3 @@ menu.push[disabled="true"]:hover,
menu.push[disabled="true"]:hover:active {
color: GrayText;
}
/* ::::: askSendFormat.xul ::::: */
#askSendFormat {
width: 40em;
}
#askImageBox {
-moz-box-align: start;
}
#convertYes,
#convertAltering {
list-style-image:url("chrome://global/skin/icons/Question.png");
}
#convertNo {
list-style-image:url("chrome://global/skin/icons/Warning.png");
}
/* Workaround for bug 50217. Please remove this rule, when this bug is fixed. */
#convertDefault {
list-style-image:url("chrome://global/skin/icons/Question.png");
}

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

@ -1,6 +1,6 @@
/* ::::: Folder Pane ::::: */
.tabmail-tab[type="folder"] > .tab-image-middle > .tab-icon > .tab-icon-image,
.tabmail-tab[type="folder"] > .tab-image-middle > .tab-icon-image,
treechildren::-moz-tree-image(folderNameCol) {
background-position: center center;
background-repeat: no-repeat;
@ -29,7 +29,7 @@ treechildren::-moz-tree-image(folderNameCol, selected, open, newMessages-true) {
/* ..... Newsgroup ..... */
.tabmail-tab[type="folder"][ServerType="nntp"] > .tab-image-middle > .tab-icon > .tab-icon-image,
.tabmail-tab[type="folder"][ServerType="nntp"] > .tab-image-middle > .tab-icon-image,
treechildren::-moz-tree-image(folderNameCol, serverType-nntp) {
background-image: none;
list-style-image: url("chrome://messenger/skin/icons/folder.png");
@ -38,7 +38,7 @@ treechildren::-moz-tree-image(folderNameCol, serverType-nntp) {
/* ..... Feed ..... */
.tabmail-tab[type="folder"][ServerType="rss"] > .tab-image-middle > .tab-icon > .tab-icon-image,
.tabmail-tab[type="folder"][ServerType="rss"] > .tab-image-middle > .tab-icon-image,
treechildren::-moz-tree-image(folderNameCol, serverType-rss) {
background-image: url("chrome://messenger/skin/icons/folder-pane.png");
background-position: left -112px;
@ -53,8 +53,8 @@ treechildren::-moz-tree-image(folderNameCol, serverType-rss, newMessages-true) {
/* Resets list-style-image for Feed Trash and Virtual folders */
.tabmail-tab[type="folder"][SpecialFolder="Trash"][ServerType="rss"] > .tab-image-middle > .tab-icon > .tab-icon-image,
.tabmail-tab[type="folder"][SpecialFolder="Virtual"][ServerType="rss"] > .tab-image-middle > .tab-icon > .tab-icon-image,
.tabmail-tab[type="folder"][SpecialFolder="Trash"][ServerType="rss"] > .tab-image-middle > .tab-icon-image,
.tabmail-tab[type="folder"][SpecialFolder="Virtual"][ServerType="rss"] > .tab-image-middle > .tab-icon-image,
treechildren::-moz-tree-image(folderNameCol, serverType-rss, specialFolder-Trash),
treechildren::-moz-tree-image(folderNameCol, serverType-rss, specialFolder-Virtual) {
background-image: url("chrome://messenger/skin/icons/folder-pane.png");
@ -64,7 +64,7 @@ treechildren::-moz-tree-image(folderNameCol, serverType-rss, specialFolder-Virtu
/* ..... Inbox ..... */
.tabmail-tab[type="folder"][SpecialFolder="Inbox"] > .tab-image-middle > .tab-icon > .tab-icon-image,
.tabmail-tab[type="folder"][SpecialFolder="Inbox"] > .tab-image-middle > .tab-icon-image,
treechildren::-moz-tree-image(folderNameCol, specialFolder-Inbox) {
background-image: url("chrome://messenger/skin/icons/folder-pane.png");
background-position: left -64px;
@ -79,7 +79,7 @@ treechildren::-moz-tree-image(folderNameCol, specialFolder-Inbox, newMessages-tr
/* ..... Sent ..... */
.tabmail-tab[type="folder"][SpecialFolder="Sent"] > .tab-image-middle > .tab-icon > .tab-icon-image,
.tabmail-tab[type="folder"][SpecialFolder="Sent"] > .tab-image-middle > .tab-icon-image,
treechildren::-moz-tree-image(folderNameCol, specialFolder-Sent) {
background-image: url("chrome://messenger/skin/icons/folder-pane.png");
background-position: left -144px;
@ -88,7 +88,7 @@ treechildren::-moz-tree-image(folderNameCol, specialFolder-Sent) {
/* ..... Outbox ..... */
.tabmail-tab[type="folder"][SpecialFolder="Outbox"] > .tab-image-middle > .tab-icon > .tab-icon-image,
.tabmail-tab[type="folder"][SpecialFolder="Outbox"] > .tab-image-middle > .tab-icon-image,
treechildren::-moz-tree-image(folderNameCol, specialFolder-Outbox) {
background-image: url("chrome://messenger/skin/icons/folder-pane.png");
background-position: left -96px;
@ -97,7 +97,7 @@ treechildren::-moz-tree-image(folderNameCol, specialFolder-Outbox) {
/* ..... Drafts ..... */
.tabmail-tab[type="folder"][SpecialFolder="Drafts"] > .tab-image-middle > .tab-icon > .tab-icon-image,
.tabmail-tab[type="folder"][SpecialFolder="Drafts"] > .tab-image-middle > .tab-icon-image,
treechildren::-moz-tree-image(folderNameCol, specialFolder-Drafts) {
background-image: url("chrome://messenger/skin/icons/folder-pane.png");
background-position: left -48px;
@ -106,7 +106,7 @@ treechildren::-moz-tree-image(folderNameCol, specialFolder-Drafts) {
/* ..... Templates ..... */
.tabmail-tab[type="folder"][SpecialFolder="Templates"] > .tab-image-middle > .tab-icon > .tab-icon-image,
.tabmail-tab[type="folder"][SpecialFolder="Templates"] > .tab-image-middle > .tab-icon-image,
treechildren::-moz-tree-image(folderNameCol, specialFolder-Templates) {
background-image: url("chrome://messenger/skin/icons/folder-pane.png");
background-position: left -160px;
@ -115,7 +115,7 @@ treechildren::-moz-tree-image(folderNameCol, specialFolder-Templates) {
/* ..... Junk ..... */
.tabmail-tab[type="folder"][SpecialFolder="Junk"] > .tab-image-middle > .tab-icon > .tab-icon-image,
.tabmail-tab[type="folder"][SpecialFolder="Junk"] > .tab-image-middle > .tab-icon-image,
treechildren::-moz-tree-image(folderNameCol, specialFolder-Junk) {
background-image: url("chrome://messenger/skin/icons/folder-pane.png");
background-position: left -80px;
@ -124,7 +124,7 @@ treechildren::-moz-tree-image(folderNameCol, specialFolder-Junk) {
/* ..... Trash ..... */
.tabmail-tab[type="folder"][SpecialFolder="Trash"] > .tab-image-middle > .tab-icon > .tab-icon-image,
.tabmail-tab[type="folder"][SpecialFolder="Trash"] > .tab-image-middle > .tab-icon-image,
treechildren::-moz-tree-image(folderNameCol, specialFolder-Trash) {
background-image: url("chrome://messenger/skin/icons/folder-pane.png");
background-position: left -176px;
@ -133,7 +133,7 @@ treechildren::-moz-tree-image(folderNameCol, specialFolder-Trash) {
/* ..... Archives ..... */
.tabmail-tab[type="folder"][SpecialFolder="Archive"] > .tab-image-middle > .tab-icon > .tab-icon-image,
.tabmail-tab[type="folder"][SpecialFolder="Archive"] > .tab-image-middle > .tab-icon-image,
treechildren::-moz-tree-image(folderNameCol, specialFolder-Archive) {
background-image: url("chrome://messenger/skin/icons/folder-pane.png");
background-position: left -192px;
@ -150,7 +150,7 @@ treechildren::-moz-tree-image(folderNameCol, imapShared-true) {
/* ..... Saved Search Folder ..... */
.tabmail-tab[type="folder"][SpecialFolder="Virtual"] > .tab-image-middle > .tab-icon > .tab-icon-image,
.tabmail-tab[type="folder"][SpecialFolder="Virtual"] > .tab-image-middle > .tab-icon-image,
treechildren::-moz-tree-image(folderNameCol, specialFolder-Virtual) {
background-image: url("chrome://messenger/skin/icons/folder-pane.png");
background-position: left -128px;
@ -158,14 +158,14 @@ treechildren::-moz-tree-image(folderNameCol, specialFolder-Virtual) {
}
/* ..... Newsgroup ..... */
.tabmail-tab[type="folder"][ServerType="nntp"] > .tab-image-middle > .tab-icon > .tab-icon-image {
.tabmail-tab[type="folder"][ServerType="nntp"] > .tab-image-middle > .tab-icon-image {
background-image: url("chrome://messenger/skin/icons/folder-pane.png");
background-position: left -208px;
list-style-image: url("chrome://messenger/skin/icons/folder-blank.png");
}
/* ..... Account nodes ..... */
.tabmail-tab[type="folder"][IsServer="true"] > .tab-image-middle > .tab-icon > .tab-icon-image {
.tabmail-tab[type="folder"][IsServer="true"] > .tab-image-middle > .tab-icon-image {
-moz-margin-start: 0px;
background-image: url("chrome://messenger/skin/icons/folder-pane.png");
background-position: left -16px;
@ -173,27 +173,27 @@ treechildren::-moz-tree-image(folderNameCol, specialFolder-Virtual) {
}
/* ..... Secure IMAP/POP account nodes ..... */
.tabmail-tab[type="folder"][IsServer="true"][ServerType="imap"][IsSecure="true"] > .tab-image-middle > .tab-icon > .tab-icon-image,
.tabmail-tab[type="folder"][IsServer="true"][ServerType="pop3"][IsSecure="true"] > .tab-image-middle > .tab-icon > .tab-icon-image {
.tabmail-tab[type="folder"][IsServer="true"][ServerType="imap"][IsSecure="true"] > .tab-image-middle > .tab-icon-image,
.tabmail-tab[type="folder"][IsServer="true"][ServerType="pop3"][IsSecure="true"] > .tab-image-middle > .tab-icon-image {
background-position: left -16px;
list-style-image: url("chrome://messenger/skin/icons/folder-blank.png");
}
/* ..... Local folders ..... */
.tabmail-tab[type="folder"][IsServer="true"][ServerType="none"] > .tab-image-middle > .tab-icon > .tab-icon-image {
.tabmail-tab[type="folder"][IsServer="true"][ServerType="none"] > .tab-image-middle > .tab-icon-image {
background-position: left 0px;
list-style-image: url("chrome://messenger/skin/icons/folder-blank.png");
}
/* ..... News server ..... */
.tabmail-tab[type="folder"][IsServer="true"][ServerType="nntp"] > .tab-image-middle > .tab-icon > .tab-icon-image {
.tabmail-tab[type="folder"][IsServer="true"][ServerType="nntp"] > .tab-image-middle > .tab-icon-image {
background-image: none;
list-style-image: url("chrome://messenger/skin/icons/server.png");
-moz-image-region: rect(0 64px 16px 48px);
}
/* ..... Secure news server ..... */
.tabmail-tab[type="folder"][IsServer="true"][ServerType="nntp"][IsSecure="true"] > .tab-image-middle > .tab-icon > .tab-icon-image {
.tabmail-tab[type="folder"][IsServer="true"][ServerType="nntp"][IsSecure="true"] > .tab-image-middle > .tab-icon-image {
background-image: none;
list-style-image: url("chrome://messenger/skin/icons/server.png");
-moz-image-region: rect(0 80px 16px 64px);
@ -263,7 +263,7 @@ treechildren::-moz-tree-image(folderNameCol, isServer-true, serverType-nntp, isS
/* ..... Feed server ..... */
.tabmail-tab[type="folder"][IsServer="true"][ServerType="rss"] > .tab-image-middle > .tab-icon > .tab-icon-image,
.tabmail-tab[type="folder"][IsServer="true"][ServerType="rss"] > .tab-image-middle > .tab-icon-image,
treechildren::-moz-tree-image(folderNameCol, isServer-true, serverType-rss) {
background-position: left -32px;
list-style-image: url("chrome://messenger/skin/icons/folder-blank.png");

Двоичный файл не отображается.

До

Ширина:  |  Высота:  |  Размер: 7.3 KiB

После

Ширина:  |  Высота:  |  Размер: 4.1 KiB

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

@ -82,15 +82,15 @@ tabpanels {
-moz-image-region: rect(0px, 16px, 16px, 0px);
}
.tabmail-tab[busy] > .tab-image-middle > .tab-icon > .tab-icon-image {
.tabmail-tab[busy] > .tab-image-middle > .tab-icon-image {
list-style-image: url("chrome://global/skin/icons/loading_16.png") !important;
}
.tabmail-tab[thinking] > .tab-image-middle > .tab-icon > .tab-icon-image {
.tabmail-tab[thinking] > .tab-image-middle > .tab-icon-image {
list-style-image: url("chrome://global/skin/icons/loading_16.png") !important;
}
.tabmail-tab[type="glodaSearch"] > .tab-image-middle > .tab-icon > .tab-icon-image {
.tabmail-tab[type="glodaSearch"] > .tab-image-middle > .tab-icon-image {
list-style-image: url("chrome://global/skin/icons/Search-glass.png");
}

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

@ -1,110 +0,0 @@
<?xml version="1.0"?>
# ***** BEGIN LICENSE BLOCK *****
# Version: MPL 1.1/GPL 2.0/LGPL 2.1
#
# The contents of this file are subject to the Mozilla Public License Version
# 1.1 (the "License"); you may not use this file except in compliance with
# the License. You may obtain a copy of the License at
# http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS IS" basis,
# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
# for the specific language governing rights and limitations under the
# License.
#
# The Original Code is tab mail
#
# The Initial Developer of the Original Code is
# Scott MacGregor <mscott@mozilla.org>.
# Portions created by the Initial Developer are Copyright (C) 2007
# the Initial Developer. All Rights Reserved.
#
# Contributor(s):
#
# Alternatively, the contents of this file may be used under the terms of
# either the GNU General Public License Version 2 or later (the "GPL"), or
# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
# in which case the provisions of the GPL or the LGPL are applicable instead
# of those above. If you wish to allow use of your version of this file only
# under the terms of either the GPL or the LGPL, and not to allow others to
# use your version of this file under the terms of the MPL, indicate your
# decision by deleting the provisions above and replace them with the notice
# and other provisions required by the GPL or the LGPL. If you do not delete
# the provisions above, a recipient may use your version of this file under
# the terms of any one of the MPL, the GPL or the LGPL.
#
# ***** END LICENSE BLOCK *****
<!DOCTYPE bindings [
<!ENTITY % tabMailDTD SYSTEM "chrome://messenger/locale/tabmail.dtd" >
%tabMailDTD;
<!ENTITY % globalDTD SYSTEM "chrome://global/locale/global.dtd">
%globalDTD;
]>
<bindings id="globalBindings"
xmlns="http://www.mozilla.org/xbl"
xmlns:xul="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"
xmlns:xbl="http://www.mozilla.org/xbl">
<binding id="tabmail-tab" extends="chrome://messenger/content/tabmail.xml#tabmail-tab">
<content chromedir="&locale.dir;"
closetabtext="&closeTab.label;">
<xul:hbox class="tab-image-left" xbl:inherits="selected"/>
<xul:hbox flex="1" class="tab-image-middle" align="center" xbl:inherits="selected">
<xul:stack class="tab-icon">
<xul:image xbl:inherits="validate,src=image" class="tab-icon-image"/>
<xul:image class="tab-extra-status"/>
</xul:stack>
<xul:label flex="1" xbl:inherits="value=label,crop,accesskey" crop="right" class="tab-text"/>
</xul:hbox>
<xul:toolbarbutton anonid="close-button" class="tab-close-button" tabindex="-1"/>
<xul:hbox class="tab-image-right" xbl:inherits="selected"/>
</content>
</binding>
<binding id="tabmail-tabs"
extends="chrome://messenger/content/tabmail.xml#tabmail-tabs">
<content>
<xul:stack flex="1" class="tabs-stack">
<xul:vbox>
<xul:spacer flex="1"/>
<xul:hbox class="tabs-bottom" align="center"/>
</xul:vbox>
<xul:vbox>
<xul:hbox>
<xul:stack>
<xul:spacer class="tabs-left"/>
</xul:stack>
<xul:arrowscrollbox anonid="arrowscrollbox"
orient="horizontal"
flex="1"
style="min-width: 1px;"
chromedir="&locale.dir;"
class="tabmail-arrowscrollbox">
<children includes="tab"/>
</xul:arrowscrollbox>
<children/>
<xul:stack align="center" pack="end" chromedir="&locale.dir;">
<xul:hbox flex="1"
class="tabs-alltabs-box"
anonid="alltabs-box"/>
<xul:hbox flex="1" class="tabs-alltabs-box-animate"
anonid="alltabs-box-animate"/>
<xul:toolbarbutton class="tabs-alltabs-button" type="menu"
anonid="alltabs-button"
tooltipstring="&listAllTabs.label;">
<xul:menupopup class="tabs-alltabs-popup"
anonid="alltabs-popup" position="after_end"/>
</xul:toolbarbutton>
</xul:stack>
<xul:hbox class="tabs-closebutton-box" align="center" pack="end" anonid="tabstrip-closebutton">
<xul:toolbarbutton class="close-button tabs-closebutton"/>
</xul:hbox>
</xul:hbox>
<xul:spacer class="tabs-bottom-spacer"/>
</xul:vbox>
</xul:stack>
</content>
</binding>
</bindings>

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

@ -25,7 +25,6 @@ classic.jar:
skin/classic/messenger/virtualFolderListDialog.css (mail/virtualFolderListDialog.css)
skin/classic/messenger/searchDialog.css (mail/searchDialog.css)
skin/classic/messenger/filterDialog.css (mail/filterDialog.css)
* skin/classic/messenger/tabmailBindings.xml (mail/tabmailBindings.xml)
skin/classic/messenger/tabmail.css (mail/tabmail.css)
skin/classic/messenger/editContactOverlay.css (mail/editContactOverlay.css)
skin/classic/messenger/starred48.png (mail/starred48.png)

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

@ -67,33 +67,3 @@ menu.push[disabled="true"]:hover,
menu.push[disabled="true"]:hover:active {
color: GrayText;
}
/* ::::: askSendFormat.xul ::::: */
#askSendFormat {
width: 40em;
}
#askImageBox {
-moz-box-align: start;
}
#convertYes {
list-style-image:url("chrome://global/skin/question-icon.png");
}
#convertAltering {
list-style-image:url("chrome://global/skin/question-icon.png");
}
#convertNo {
list-style-image:url("chrome://global/skin/alert-icon.png");
}
/* Workaround for bug 50217. Please remove this rule, when this bug is fixed. */
#convertDefault {
list-style-image:url("chrome://global/skin/question-icon.png");
}

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

@ -35,16 +35,6 @@
/* ::::: tabmail ::::: */
/* bring in the proper bindings on OS X */
.tabmail-tab {
-moz-binding: url("chrome://messenger/skin/tabmailBindings.xml#tabmail-tab") !important;
}
.tabmail-tabs {
-moz-binding: url("chrome://messenger/skin/tabmailBindings.xml#tabmail-tabs") !important;
}
.tabmail-tabs > .tabmail-tab:first-child > .tab-close-button {
visibility: collapse;
}

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

@ -1,102 +0,0 @@
<?xml version="1.0"?>
# ***** BEGIN LICENSE BLOCK *****
# Version: MPL 1.1/GPL 2.0/LGPL 2.1
#
# The contents of this file are subject to the Mozilla Public License Version
# 1.1 (the "License"); you may not use this file except in compliance with
# the License. You may obtain a copy of the License at
# http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS IS" basis,
# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
# for the specific language governing rights and limitations under the
# License.
#
# The Original Code is tab mail
#
# The Initial Developer of the Original Code is
# Scott MacGregor <mscott@mozilla.org>.
# Portions created by the Initial Developer are Copyright (C) 2007
# the Initial Developer. All Rights Reserved.
#
# Contributor(s):
#
# Alternatively, the contents of this file may be used under the terms of
# either the GNU General Public License Version 2 or later (the "GPL"), or
# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
# in which case the provisions of the GPL or the LGPL are applicable instead
# of those above. If you wish to allow use of your version of this file only
# under the terms of either the GPL or the LGPL, and not to allow others to
# use your version of this file under the terms of the MPL, indicate your
# decision by deleting the provisions above and replace them with the notice
# and other provisions required by the GPL or the LGPL. If you do not delete
# the provisions above, a recipient may use your version of this file under
# the terms of any one of the MPL, the GPL or the LGPL.
#
# ***** END LICENSE BLOCK *****
<!DOCTYPE bindings [
<!ENTITY % tabMailDTD SYSTEM "chrome://messenger/locale/tabmail.dtd" >
%tabMailDTD;
<!ENTITY % globalDTD SYSTEM "chrome://global/locale/global.dtd">
%globalDTD;
]>
<bindings id="globalBindings"
xmlns="http://www.mozilla.org/xbl"
xmlns:xul="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"
xmlns:xbl="http://www.mozilla.org/xbl">
<binding id="tabmail-tab" extends="chrome://messenger/content/tabmail.xml#tabmail-tab">
<content chromedir="&locale.dir;"
closetabtext="&closeTab.label;">
<xul:hbox class="tab-image-left" xbl:inherits="selected"/>
<xul:hbox flex="1" class="tab-image-middle" align="center" xbl:inherits="selected">
<xul:image xbl:inherits="validate,src=image,selected" class="tab-icon-image"/>
<xul:label flex="1" xbl:inherits="value=label,crop,accesskey" crop="right" class="tab-text"/>
</xul:hbox>
<xul:toolbarbutton anonid="close-button" class="tab-close-button" tabindex="-1"/>
<xul:hbox class="tab-image-right" xbl:inherits="selected"/>
</content>
</binding>
<binding id="tabmail-tabs"
extends="chrome://messenger/content/tabmail.xml#tabmail-tabs">
<content>
<xul:stack flex="1" class="tabs-stack">
<xul:vbox>
<xul:spacer flex="1"/>
<xul:hbox class="tabs-bottom" align="center"/>
</xul:vbox>
<xul:vbox>
<xul:hbox>
<xul:stack>
<xul:spacer class="tabs-left"/>
</xul:stack>
<xul:arrowscrollbox anonid="arrowscrollbox" orient="horizontal" flex="1" style="min-width: 1px;" class="tabmail-arrowscrollbox">
<children includes="tab"/>
</xul:arrowscrollbox>
<children/>
<xul:stack align="center" pack="end">
<xul:hbox flex="1" class="tabs-alltabs-box"
anonid="alltabs-box"/>
<xul:hbox flex="1" class="tabs-alltabs-box-animate"
anonid="alltabs-box-animate"/>
<xul:toolbarbutton class="tabs-alltabs-button"
type="menu"
anonid="alltabs-button"
tooltipstring="&listAllTabs.label;">
<xul:menupopup class="tabs-alltabs-popup"
anonid="alltabs-popup" position="after_end"/>
</xul:toolbarbutton>
</xul:stack>
<xul:hbox class="tabs-closebutton-box" align="center" pack="end" anonid="tabstrip-closebutton">
<xul:toolbarbutton class="close-button tabs-closebutton"/>
</xul:hbox>
</xul:hbox>
<xul:spacer class="tabs-bottom-spacer"/>
</xul:vbox>
</xul:stack>
</content>
</binding>
</bindings>

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

@ -69,7 +69,6 @@ classic.jar:
skin/classic/messenger/icons/exclude.png (mail/icons/exclude.png)
skin/classic/messenger/icons/exclude-selected.png (mail/icons/exclude-selected.png)
skin/classic/messenger/newmailalert.css (mail/newmailalert.css)
* skin/classic/messenger/tabmailBindings.xml (mail/tabmailBindings.xml)
skin/classic/messenger/tabmail.css (mail/tabmail.css)
skin/classic/messenger/editContactOverlay.css (mail/editContactOverlay.css)
skin/classic/messenger/starred48.png (mail/starred48.png)
@ -263,7 +262,6 @@ classic.jar:
skin/classic/aero/messenger/icons/exclude.png (mail/icons/exclude.png)
skin/classic/aero/messenger/icons/exclude-selected.png (mail/icons/exclude-selected.png)
skin/classic/aero/messenger/newmailalert.css (mail/newmailalert.css)
* skin/classic/aero/messenger/tabmailBindings.xml (mail/tabmailBindings.xml)
skin/classic/aero/messenger/tabmail.css (mail/tabmail.css)
skin/classic/aero/messenger/editContactOverlay.css (mail/editContactOverlay.css)
skin/classic/aero/messenger/starred48.png (mail/starred48.png)

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

@ -67,27 +67,3 @@ menu.push[disabled="true"]:hover,
menu.push[disabled="true"]:hover:active {
color: GrayText;
}
/* ::::: askSendFormat.xul ::::: */
#askSendFormat {
width: 40em;
}
#askImageBox {
-moz-box-align: start;
}
#convertYes,
#convertAltering {
list-style-image:url("chrome://global/skin/icons/Question.png");
}
#convertNo {
list-style-image:url("chrome://global/skin/icons/Warning.png");
}
/* Workaround for bug 50217. Please remove this rule, when this bug is fixed. */
#convertDefault {
list-style-image:url("chrome://global/skin/icons/Question.png");
}

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

@ -38,7 +38,6 @@
*/
.tabmail-tabs {
-moz-binding: url("chrome://messenger/skin/tabmailBindings.xml#tabmail-tabs") !important;
padding-top: 0px;
background: -moz-dialog url("chrome://messenger/skin/tabmail-tabs-bkgnd.png") !important;
-moz-padding-start: 0px;
@ -58,7 +57,6 @@
.tabmail-tab {
-moz-appearance: none !important;
-moz-binding: url("chrome://messenger/skin/tabmailBindings.xml#tabmail-tab") !important;
background: transparent !important;
margin: 0px 0px 1px !important;
padding: 0px !important;

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

@ -1,107 +0,0 @@
<?xml version="1.0"?>
# ***** BEGIN LICENSE BLOCK *****
# Version: MPL 1.1/GPL 2.0/LGPL 2.1
#
# The contents of this file are subject to the Mozilla Public License Version
# 1.1 (the "License"); you may not use this file except in compliance with
# the License. You may obtain a copy of the License at
# http://www.mozilla.org/MPL/
#
# Software distributed under the License is distributed on an "AS IS" basis,
# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
# for the specific language governing rights and limitations under the
# License.
#
# The Original Code is tab mail
#
# The Initial Developer of the Original Code is
# Scott MacGregor <mscott@mozilla.org>.
# Portions created by the Initial Developer are Copyright (C) 2007
# the Initial Developer. All Rights Reserved.
#
# Contributor(s):
#
# Alternatively, the contents of this file may be used under the terms of
# either the GNU General Public License Version 2 or later (the "GPL"), or
# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
# in which case the provisions of the GPL or the LGPL are applicable instead
# of those above. If you wish to allow use of your version of this file only
# under the terms of either the GPL or the LGPL, and not to allow others to
# use your version of this file under the terms of the MPL, indicate your
# decision by deleting the provisions above and replace them with the notice
# and other provisions required by the GPL or the LGPL. If you do not delete
# the provisions above, a recipient may use your version of this file under
# the terms of any one of the MPL, the GPL or the LGPL.
#
# ***** END LICENSE BLOCK *****
<!DOCTYPE bindings [
<!ENTITY % tabMailDTD SYSTEM "chrome://messenger/locale/tabmail.dtd" >
%tabMailDTD;
<!ENTITY % globalDTD SYSTEM "chrome://global/locale/global.dtd">
%globalDTD;
]>
<bindings id="globalBindings"
xmlns="http://www.mozilla.org/xbl"
xmlns:xul="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"
xmlns:xbl="http://www.mozilla.org/xbl">
<binding id="tabmail-tab" extends="chrome://messenger/content/tabmail.xml#tabmail-tab">
<content chromedir="&locale.dir;"
closetabtext="&closeTab.label;">
<xul:hbox class="tab-image-left" xbl:inherits="selected"/>
<xul:hbox flex="1" class="tab-image-middle" align="center" xbl:inherits="selected">
<xul:image xbl:inherits="validate,src=image" class="tab-icon-image"/>
<xul:label flex="1" xbl:inherits="value=label,crop,accesskey" crop="right" class="tab-text"/>
</xul:hbox>
<xul:toolbarbutton anonid="close-button" class="tab-close-button" tabindex="-1"/>
<xul:hbox class="tab-image-right" xbl:inherits="selected"/>
</content>
</binding>
<binding id="tabmail-tabs"
extends="chrome://messenger/content/tabmail.xml#tabmail-tabs">
<content>
<xul:stack flex="1" class="tabs-stack">
<xul:vbox>
<xul:spacer flex="1"/>
<xul:hbox class="tabs-bottom" align="center"/>
</xul:vbox>
<xul:vbox>
<xul:hbox>
<xul:stack>
<xul:spacer class="tabs-left"/>
</xul:stack>
<xul:arrowscrollbox anonid="arrowscrollbox"
orient="horizontal"
flex="1"
style="min-width: 1px;"
chromedir="&locale.dir;"
class="tabmail-arrowscrollbox">
<children includes="tab"/>
</xul:arrowscrollbox>
<children/>
<xul:stack align="center" pack="end" chromedir="&locale.dir;">
<xul:hbox flex="1"
class="tabs-alltabs-box"
anonid="alltabs-box"/>
<xul:hbox flex="1" class="tabs-alltabs-box-animate"
anonid="alltabs-box-animate"/>
<xul:toolbarbutton class="tabs-alltabs-button" type="menu"
anonid="alltabs-button"
tooltipstring="&listAllTabs.label;">
<xul:menupopup class="tabs-alltabs-popup"
anonid="alltabs-popup" position="after_end"/>
</xul:toolbarbutton>
</xul:stack>
<xul:hbox class="tabs-closebutton-box" align="center" pack="end" anonid="tabstrip-closebutton">
<xul:toolbarbutton class="close-button tabs-closebutton"/>
</xul:hbox>
</xul:hbox>
<xul:spacer class="tabs-bottom-spacer"/>
</xul:vbox>
</xul:stack>
</content>
</binding>
</bindings>

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

@ -393,66 +393,43 @@
</vbox>
<!-- ** Photo Tab ** -->
<vbox id="abPhotoTab" >
<hbox flex="1">
<vbox align="left">
<spacer flex="1"/>
<hbox id="photoBox" style="min-width: 25ch; max-width: 25ch;">
<spacer flex="1"/>
<html:img align="center" src="" id="photo"
style="max-width: 25ch; max-height: 25ch; min-width: 1ch;"/>
<spacer flex="1"/>
<hbox id="abPhotoTab" align="center">
<description style="min-width: 25ch; max-width: 25ch; text-align: center">
<html:img id="photo" style="max-width: 25ch; max-height: 25ch;"/>
</description>
<groupbox flex="1">
<caption label="&PhotoDesc.label;"/>
<radiogroup id="PhotoType" onselect="updatePhoto();">
<radio value="generic" label="&GenericPhoto.label;"
accesskey="&GenericPhoto.accesskey;"/>
<menulist id="GenericPhotoList" class="indent" flex="1"
oncommand="updatePhoto('generic');">
<menupopup>
<menuitem label="&DefaultPhoto.label;" selected="true"
value="chrome://messenger/skin/addressbook/icons/contact-generic.png"
image="chrome://messenger/skin/addressbook/icons/contact-generic-tiny.png"/>
</menupopup>
</menulist>
<radio value="file" label="&PhotoFile.label;"
accesskey="&PhotoFile.accesskey;"/>
<hbox class="indent">
<filefield id="PhotoFile" maxlength="255" flex="1"/>
<button oncommand="browsePhoto();" id="BrowsePhoto"
label="&BrowsePhoto.label;"
accesskey="&BrowsePhoto.accesskey;"/>
</hbox>
<spacer flex="1"/>
</vbox>
<vbox>
<command id="PhotoCmd" oncommand="updatePhoto();"/>
<spacer flex="1"/>
<groupbox flex="1">
<caption label="&PhotoDesc.label;"/>
<radiogroup id="PhotoType">
<radio id="generic" label="&GenericPhoto.label;"
command="PhotoCmd"
accesskey="&GenericPhoto.accesskey;"
selected="true"/>
<hbox class="indent">
<menulist id="GenericPhotoList"
oncommand="updatePhoto('generic');">
<menupopup>
<menuitem label="&DefaultPhoto.label;" selected="true"
value="chrome://messenger/skin/addressbook/icons/contact-generic.png"
image="chrome://messenger/skin/addressbook/icons/contact-generic-tiny.png"/>
</menupopup>
</menulist>
</hbox>
<radio id="file" label="&PhotoFile.label;"
command="PhotoCmd"
accesskey="&PhotoFile.accesskey;"/>
<hbox class="indent">
<filefield id="PhotoFile" maxlength="255" flex="1"
disabled="true"
style="-moz-margin-start:2px;"/>
<button oncommand="browsePhoto();" id="BrowsePhoto"
label="&BrowsePhoto.label;"
accesskey="&BrowsePhoto.accesskey;"/>
</hbox>
<radio id="web" label="&PhotoURL.label;"
command="PhotoCmd"
accesskey="&PhotoURL.accesskey;"/>
<hbox class="indent">
<textbox id="PhotoURI" maxlength="255" style="width: 45ch;"
emptytext="&PhotoURL.emptytext;"
class="AddressCardEditWidth"/>
<button oncommand="updatePhoto('web');" id="UpdatePhoto"
label="&UpdatePhoto.label;"
accesskey="&UpdatePhoto.accesskey;"/>
</hbox>
</radiogroup>
</groupbox>
<spacer flex="1"/>
</vbox>
</hbox>
</vbox>
<radio value="web" label="&PhotoURL.label;"
accesskey="&PhotoURL.accesskey;"/>
<hbox class="indent">
<textbox id="PhotoURI" maxlength="255" flex="1"
emptytext="&PhotoURL.emptytext;"/>
<button oncommand="updatePhoto('web');" id="UpdatePhoto"
label="&UpdatePhoto.label;"
accesskey="&UpdatePhoto.accesskey;"/>
</hbox>
</radiogroup>
</groupbox>
</hbox>
</tabpanels>
</tabbox>
</vbox>

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

@ -730,7 +730,7 @@ nsAbManager::ExportDirectoryToDelimitedText(nsIAbDirectory *aDirectory, const ch
NS_ENSURE_SUCCESS(rv,rv);
if (NS_FAILED(rv)) {
NS_ASSERTION(0, "failed to convert string to system charset. use LDIF");
NS_ERROR("failed to convert string to system charset. use LDIF");
valueCStr = "?";
}

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

@ -44,7 +44,11 @@
* globals prerequisites used:
*
* window.MsgStatusFeedback
* GetSelectedIndices(view)
*
* One of:
* GetSelectedIndices(view) (in suite)
* gFolderDisplay (in mail)
*
* messenger
* gMessengerBundle
* gDBView
@ -236,6 +240,8 @@ MessageClassifier.prototype =
*/
onMessageClassified: function(aClassifiedMsgURI, aClassification, aJunkPercent)
{
if (!aClassifiedMsgURI)
return; // ignore end of batch
var nsIJunkMailPlugin = Components.interfaces.nsIJunkMailPlugin;
var score = (aClassification == nsIJunkMailPlugin.JUNK) ?
nsIJunkMailPlugin.IS_SPAM_SCORE : nsIJunkMailPlugin.IS_HAM_SCORE;
@ -321,7 +327,10 @@ function processFolderForJunk(aAll)
}
else
{
var indices = GetSelectedIndices(gDBView);
// suite uses GetSelectedIndices, mail uses gFolderDisplay.selectedMessages
var indices = typeof GetSelectedIndices != "undefined" ?
GetSelectedIndices(gDBView) :
gFolderDisplay.selectedIndices;
if (!indices || !indices.length)
return;
}

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

@ -98,6 +98,8 @@ function onLoad()
doEnabling(); // we only need to disable/enable the OK button for new virtual folders
}
if (typeof arguments.searchOnline != "undefined")
document.getElementById('searchOnline').checked = arguments.searchOnline;
updateOnlineSearchState();
doSetOKCancel(onOK, onCancel);
}

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

@ -95,7 +95,7 @@ function openIdentityEditor(identity)
var result = false;
var args = { identity: identity, account: gAccount, result: result };
window.openDialog('am-identity-edit.xul', '', 'modal,titlebar,chrome', args);
window.openDialog("am-identity-edit.xul", "", "chrome,modal,resizable=no,centerscreen", args);
var selectedItemIndex = gIdentityListBox.selectedIndex;

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

@ -1,8 +1,4 @@
<?xml version="1.0"?>
<?xml-stylesheet href="chrome://messenger/skin/messenger.css" type="text/css"?>
<?xml-stylesheet href="chrome://messenger/skin/accountManage.css" type="text/css"?>
<!-- ***** BEGIN LICENSE BLOCK *****
Version: MPL 1.1/GPL 2.0/LGPL 2.1
@ -22,7 +18,7 @@
David Bienvenu.
Portions created by the Initial Developer are Copyright (C) 2004
the Initial Developer. All Rights Reserved.
Contributor(s):
Scott MacGregor <mscott@mozilla.org>
@ -40,6 +36,9 @@
***** END LICENSE BLOCK ***** -->
<?xml-stylesheet href="chrome://messenger/skin/messenger.css" type="text/css"?>
<?xml-stylesheet href="chrome://messenger/skin/accountManage.css" type="text/css"?>
<?xul-overlay href="chrome://messenger/content/am-copiesOverlay.xul"?>
<?xul-overlay href="chrome://messenger/content/am-addressingOverlay.xul"?>
@ -48,14 +47,14 @@
%identityEditDTD;
<!ENTITY % identityDTD SYSTEM "chrome://messenger/locale/am-main.dtd" >
%identityDTD;
]>
]>
<dialog title="&identityTitle.label;"
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"
onload="onLoadIdentityProperties();"
ondialogaccept="return onOk();"
style="width: 35em;">
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"
onload="onLoadIdentityProperties();"
ondialogaccept="return onOk();"
style="&identityDialog.style;">
<stringbundle id="bundle_prefs" src="chrome://messenger/locale/prefs.properties"/>
<stringbundle id="bundle_messenger" src="chrome://messenger/locale/messenger.properties"/>
@ -159,7 +158,7 @@
</menulist>
</hbox>
</vbox>
<!-- Copies & Folders Tab -->
<vbox flex="1" name="copiesAndFolders" id="copiesAndFolders"/>

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

@ -78,7 +78,7 @@ function manageIdentities()
var identity = account.defaultIdentity;
saveIdentitySettings(identity);
window.openDialog('am-identities-list.xul', 'identity', 'modal,titlebar,chrome', args);
window.openDialog("am-identities-list.xul", "", "chrome,modal,resizable=no,centerscreen", args);
if (args.result) {
// now re-initialize the default identity settings in case they changed

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

@ -59,7 +59,7 @@ interface nsIURI;
* often you will want to add extra interfaces that give you server-specific
* attributes and methods.
*/
[scriptable, uuid(20B4A762-10F5-4ce7-99CC-F07C10236E20)]
[scriptable, uuid(cca9b826-24d8-4b76-b229-b8b12f1ecbd5)]
interface nsIMsgIncomingServer : nsISupports {
/**
@ -123,8 +123,24 @@ interface nsIMsgIncomingServer : nsISupports {
/* cleartext version of the password */
attribute ACString password;
/* prompt the user for a password */
ACString getPasswordWithUI(in AString aPromptString, in AString aPromptTitle, in nsIMsgWindow aMsgWindow, out boolean okayValue);
/**
* Attempts to get the password first from the password manager, if that
* fails it will attempt to get it from the user if aMsgWindow is supplied.
*
* @param aPromptString The text of the prompt if the user is prompted for
* password.
* @param aPromptTitle The title of the prompt if the user is prompted.
* @param aMsgWindow A message window to associate the prompt with.
* @return The obtained password. Could be an empty password.
*
* @exception NS_ERROR_FAILURE The password could not be obtained.
*
* @note NS_MSG_PASSWORD_PROMPT_CANCELLED is a success code that is returned
* if the prompt was presented to the user but the user cancelled the
* prompt.
*/
ACString getPasswordWithUI(in AString aPromptString, in AString aPromptTitle,
in nsIMsgWindow aMsgWindow);
/* forget the password in memory and in single signon database */
void forgetPassword();

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

@ -202,8 +202,13 @@ protected:
nsCOMPtr<nsIMsgSearchValidityTable> m_onlineMailFilterTable;
nsCOMPtr<nsIMsgSearchValidityTable> m_onlineManualFilterTable;
nsCOMPtr<nsIMsgSearchValidityTable> m_newsTable;
nsCOMPtr<nsIMsgSearchValidityTable> m_localNewsTable; // used for local news searching or offline news searching...
nsCOMPtr<nsIMsgSearchValidityTable> m_newsTable; // online news
// Local news tables, used for local news searching or offline.
nsCOMPtr<nsIMsgSearchValidityTable> m_localNewsTable; // base table
nsCOMPtr<nsIMsgSearchValidityTable> m_localNewsJunkTable; // base + junk
nsCOMPtr<nsIMsgSearchValidityTable> m_localNewsBodyTable; // base + body
nsCOMPtr<nsIMsgSearchValidityTable> m_localNewsJunkBodyTable; // base + junk + body
nsCOMPtr<nsIMsgSearchValidityTable> m_ldapTable;
nsCOMPtr<nsIMsgSearchValidityTable> m_ldapAndTable;
nsCOMPtr<nsIMsgSearchValidityTable> m_localABTable;
@ -219,6 +224,9 @@ protected:
nsresult InitOnlineManualFilterTable();
nsresult InitNewsTable();
nsresult InitLocalNewsTable();
nsresult InitLocalNewsJunkTable();
nsresult InitLocalNewsBodyTable();
nsresult InitLocalNewsJunkBodyTable();
nsresult InitNewsFilterTable();
//set the custom headers in the table, changes whenever "mailnews.customHeaders" pref changes.

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

@ -53,6 +53,7 @@ interface nsMsgSearchScope {
const nsMsgSearchScopeValue offlineMailFilter = 1;
const nsMsgSearchScopeValue onlineMail = 2;
const nsMsgSearchScopeValue onlineMailFilter = 3;
/// offline news, base table, no body or junk
const nsMsgSearchScopeValue localNews = 4;
const nsMsgSearchScopeValue news = 5;
const nsMsgSearchScopeValue newsEx = 6;
@ -64,6 +65,12 @@ interface nsMsgSearchScope {
const nsMsgSearchScopeValue LDAPAnd = 12;
// IMAP and NEWS, searched using local headers
const nsMsgSearchScopeValue onlineManual = 13;
/// local news + junk
const nsMsgSearchScopeValue localNewsJunk = 14;
/// local news + body
const nsMsgSearchScopeValue localNewsBody = 15;
/// local news + junk + body
const nsMsgSearchScopeValue localNewsJunkBody = 16;
};
typedef long nsMsgSearchAttribValue;

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

@ -878,76 +878,168 @@ nsresult nsMsgSearchOfflineNews::ValidateTerms ()
return nsMsgSearchOfflineMail::ValidateTerms ();
}
// local helper functions to set subsets of the validity table
//-----------------------------------------------------------------------------
nsresult nsMsgSearchValidityManager::InitLocalNewsTable()
nsresult SetJunk(nsIMsgSearchValidityTable* aTable)
{
NS_ASSERTION (nsnull == m_localNewsTable, "already have local news validty table");
nsresult err = NewTable (getter_AddRefs(m_localNewsTable));
NS_ENSURE_ARG_POINTER(aTable);
if (NS_SUCCEEDED(err))
{
m_localNewsTable->SetAvailable (nsMsgSearchAttrib::Sender, nsMsgSearchOp::Contains, 1);
m_localNewsTable->SetEnabled (nsMsgSearchAttrib::Sender, nsMsgSearchOp::Contains, 1);
m_localNewsTable->SetAvailable (nsMsgSearchAttrib::Sender, nsMsgSearchOp::Is, 1);
m_localNewsTable->SetEnabled (nsMsgSearchAttrib::Sender, nsMsgSearchOp::Is, 1);
m_localNewsTable->SetAvailable (nsMsgSearchAttrib::Sender, nsMsgSearchOp::BeginsWith, 1);
m_localNewsTable->SetEnabled (nsMsgSearchAttrib::Sender, nsMsgSearchOp::BeginsWith, 1);
m_localNewsTable->SetAvailable (nsMsgSearchAttrib::Sender, nsMsgSearchOp::EndsWith, 1);
m_localNewsTable->SetEnabled (nsMsgSearchAttrib::Sender, nsMsgSearchOp::EndsWith, 1);
aTable->SetAvailable(nsMsgSearchAttrib::JunkStatus, nsMsgSearchOp::Is, 1);
aTable->SetEnabled(nsMsgSearchAttrib::JunkStatus, nsMsgSearchOp::Is, 1);
aTable->SetAvailable(nsMsgSearchAttrib::JunkStatus, nsMsgSearchOp::Isnt, 1);
aTable->SetEnabled(nsMsgSearchAttrib::JunkStatus, nsMsgSearchOp::Isnt, 1);
m_localNewsTable->SetAvailable (nsMsgSearchAttrib::Subject, nsMsgSearchOp::Contains, 1);
m_localNewsTable->SetEnabled (nsMsgSearchAttrib::Subject, nsMsgSearchOp::Contains, 1);
m_localNewsTable->SetAvailable (nsMsgSearchAttrib::Subject, nsMsgSearchOp::Is, 1);
m_localNewsTable->SetEnabled (nsMsgSearchAttrib::Subject, nsMsgSearchOp::Is, 1);
m_localNewsTable->SetAvailable (nsMsgSearchAttrib::Subject, nsMsgSearchOp::BeginsWith, 1);
m_localNewsTable->SetEnabled (nsMsgSearchAttrib::Subject, nsMsgSearchOp::BeginsWith, 1);
m_localNewsTable->SetAvailable (nsMsgSearchAttrib::Subject, nsMsgSearchOp::EndsWith, 1);
m_localNewsTable->SetEnabled (nsMsgSearchAttrib::Subject, nsMsgSearchOp::EndsWith, 1);
aTable->SetAvailable(nsMsgSearchAttrib::JunkPercent, nsMsgSearchOp::IsGreaterThan, 1);
aTable->SetEnabled(nsMsgSearchAttrib::JunkPercent, nsMsgSearchOp::IsGreaterThan, 1);
aTable->SetAvailable(nsMsgSearchAttrib::JunkPercent, nsMsgSearchOp::IsLessThan, 1);
aTable->SetEnabled(nsMsgSearchAttrib::JunkPercent, nsMsgSearchOp::IsLessThan, 1);
aTable->SetAvailable(nsMsgSearchAttrib::JunkPercent, nsMsgSearchOp::Is, 1);
aTable->SetEnabled(nsMsgSearchAttrib::JunkPercent, nsMsgSearchOp::Is, 1);
m_localNewsTable->SetAvailable (nsMsgSearchAttrib::Body, nsMsgSearchOp::Contains, 1);
m_localNewsTable->SetEnabled (nsMsgSearchAttrib::Body, nsMsgSearchOp::Contains, 1);
m_localNewsTable->SetAvailable (nsMsgSearchAttrib::Body, nsMsgSearchOp::DoesntContain, 1);
m_localNewsTable->SetEnabled (nsMsgSearchAttrib::Body, nsMsgSearchOp::DoesntContain, 1);
m_localNewsTable->SetAvailable (nsMsgSearchAttrib::Body, nsMsgSearchOp::Is, 1);
m_localNewsTable->SetEnabled (nsMsgSearchAttrib::Body, nsMsgSearchOp::Is, 1);
m_localNewsTable->SetAvailable (nsMsgSearchAttrib::Body, nsMsgSearchOp::Isnt, 1);
m_localNewsTable->SetEnabled (nsMsgSearchAttrib::Body, nsMsgSearchOp::Isnt, 1);
aTable->SetAvailable(nsMsgSearchAttrib::JunkScoreOrigin, nsMsgSearchOp::Is, 1);
aTable->SetEnabled(nsMsgSearchAttrib::JunkScoreOrigin, nsMsgSearchOp::Is, 1);
aTable->SetAvailable(nsMsgSearchAttrib::JunkScoreOrigin, nsMsgSearchOp::Isnt, 1);
aTable->SetEnabled(nsMsgSearchAttrib::JunkScoreOrigin, nsMsgSearchOp::Isnt, 1);
m_localNewsTable->SetEnabled (nsMsgSearchAttrib::Date, nsMsgSearchOp::IsBefore, 1);
m_localNewsTable->SetAvailable (nsMsgSearchAttrib::Date, nsMsgSearchOp::IsAfter, 1);
m_localNewsTable->SetEnabled (nsMsgSearchAttrib::Date, nsMsgSearchOp::IsAfter, 1);
m_localNewsTable->SetAvailable (nsMsgSearchAttrib::Date, nsMsgSearchOp::Is, 1);
m_localNewsTable->SetEnabled (nsMsgSearchAttrib::Date, nsMsgSearchOp::Is, 1);
m_localNewsTable->SetAvailable (nsMsgSearchAttrib::Date, nsMsgSearchOp::Isnt, 1);
m_localNewsTable->SetEnabled (nsMsgSearchAttrib::Date, nsMsgSearchOp::Isnt, 1);
m_localNewsTable->SetAvailable (nsMsgSearchAttrib::AgeInDays, nsMsgSearchOp::IsGreaterThan, 1);
m_localNewsTable->SetEnabled (nsMsgSearchAttrib::AgeInDays, nsMsgSearchOp::IsGreaterThan, 1);
m_localNewsTable->SetAvailable (nsMsgSearchAttrib::AgeInDays, nsMsgSearchOp::IsLessThan, 1);
m_localNewsTable->SetEnabled (nsMsgSearchAttrib::AgeInDays, nsMsgSearchOp::IsLessThan, 1);
m_localNewsTable->SetAvailable (nsMsgSearchAttrib::AgeInDays, nsMsgSearchOp::Is, 1);
m_localNewsTable->SetEnabled (nsMsgSearchAttrib::AgeInDays, nsMsgSearchOp::Is, 1);
m_localNewsTable->SetAvailable (nsMsgSearchAttrib::MsgStatus, nsMsgSearchOp::Is, 1);
m_localNewsTable->SetEnabled (nsMsgSearchAttrib::MsgStatus, nsMsgSearchOp::Is, 1);
m_localNewsTable->SetAvailable (nsMsgSearchAttrib::MsgStatus, nsMsgSearchOp::Isnt, 1);
m_localNewsTable->SetEnabled (nsMsgSearchAttrib::MsgStatus, nsMsgSearchOp::Isnt, 1);
m_localNewsTable->SetAvailable (nsMsgSearchAttrib::OtherHeader, nsMsgSearchOp::Contains, 1);
m_localNewsTable->SetEnabled (nsMsgSearchAttrib::OtherHeader, nsMsgSearchOp::Contains, 1);
m_localNewsTable->SetAvailable (nsMsgSearchAttrib::OtherHeader, nsMsgSearchOp::Is, 1);
m_localNewsTable->SetEnabled (nsMsgSearchAttrib::OtherHeader, nsMsgSearchOp::Is, 1);
m_localNewsTable->SetAvailable (nsMsgSearchAttrib::OtherHeader, nsMsgSearchOp::BeginsWith, 1);
m_localNewsTable->SetEnabled (nsMsgSearchAttrib::OtherHeader, nsMsgSearchOp::BeginsWith, 1);
m_localNewsTable->SetAvailable (nsMsgSearchAttrib::OtherHeader, nsMsgSearchOp::EndsWith, 1);
m_localNewsTable->SetEnabled (nsMsgSearchAttrib::OtherHeader, nsMsgSearchOp::EndsWith, 1);
}
return err;
return NS_OK;
}
nsresult SetBody(nsIMsgSearchValidityTable* aTable)
{
NS_ENSURE_ARG_POINTER(aTable);
aTable->SetAvailable (nsMsgSearchAttrib::Body, nsMsgSearchOp::Contains, 1);
aTable->SetEnabled (nsMsgSearchAttrib::Body, nsMsgSearchOp::Contains, 1);
aTable->SetAvailable (nsMsgSearchAttrib::Body, nsMsgSearchOp::DoesntContain, 1);
aTable->SetEnabled (nsMsgSearchAttrib::Body, nsMsgSearchOp::DoesntContain, 1);
aTable->SetAvailable (nsMsgSearchAttrib::Body, nsMsgSearchOp::Is, 1);
aTable->SetEnabled (nsMsgSearchAttrib::Body, nsMsgSearchOp::Is, 1);
aTable->SetAvailable (nsMsgSearchAttrib::Body, nsMsgSearchOp::Isnt, 1);
aTable->SetEnabled (nsMsgSearchAttrib::Body, nsMsgSearchOp::Isnt, 1);
return NS_OK;
}
// set the base validity table values for local news
nsresult SetLocalNews(nsIMsgSearchValidityTable* aTable)
{
NS_ENSURE_ARG_POINTER(aTable);
aTable->SetAvailable (nsMsgSearchAttrib::Sender, nsMsgSearchOp::Contains, 1);
aTable->SetEnabled (nsMsgSearchAttrib::Sender, nsMsgSearchOp::Contains, 1);
aTable->SetAvailable (nsMsgSearchAttrib::Sender, nsMsgSearchOp::DoesntContain, 1);
aTable->SetEnabled (nsMsgSearchAttrib::Sender, nsMsgSearchOp::DoesntContain, 1);
aTable->SetAvailable (nsMsgSearchAttrib::Sender, nsMsgSearchOp::Is, 1);
aTable->SetEnabled (nsMsgSearchAttrib::Sender, nsMsgSearchOp::Is, 1);
aTable->SetEnabled (nsMsgSearchAttrib::Sender, nsMsgSearchOp::Isnt, 1);
aTable->SetAvailable (nsMsgSearchAttrib::Sender, nsMsgSearchOp::Isnt, 1);
aTable->SetAvailable (nsMsgSearchAttrib::Sender, nsMsgSearchOp::BeginsWith, 1);
aTable->SetEnabled (nsMsgSearchAttrib::Sender, nsMsgSearchOp::BeginsWith, 1);
aTable->SetAvailable (nsMsgSearchAttrib::Sender, nsMsgSearchOp::EndsWith, 1);
aTable->SetEnabled (nsMsgSearchAttrib::Sender, nsMsgSearchOp::EndsWith, 1);
aTable->SetAvailable (nsMsgSearchAttrib::Sender, nsMsgSearchOp::IsInAB, 1);
aTable->SetEnabled (nsMsgSearchAttrib::Sender, nsMsgSearchOp::IsInAB, 1);
aTable->SetAvailable (nsMsgSearchAttrib::Sender, nsMsgSearchOp::IsntInAB, 1);
aTable->SetEnabled (nsMsgSearchAttrib::Sender, nsMsgSearchOp::IsntInAB, 1);
aTable->SetAvailable (nsMsgSearchAttrib::Subject, nsMsgSearchOp::Contains, 1);
aTable->SetEnabled (nsMsgSearchAttrib::Subject, nsMsgSearchOp::Contains, 1);
aTable->SetAvailable (nsMsgSearchAttrib::Subject, nsMsgSearchOp::DoesntContain, 1);
aTable->SetEnabled (nsMsgSearchAttrib::Subject, nsMsgSearchOp::DoesntContain, 1);
aTable->SetAvailable (nsMsgSearchAttrib::Subject, nsMsgSearchOp::Is, 1);
aTable->SetEnabled (nsMsgSearchAttrib::Subject, nsMsgSearchOp::Is, 1);
aTable->SetAvailable (nsMsgSearchAttrib::Subject, nsMsgSearchOp::Isnt, 1);
aTable->SetEnabled (nsMsgSearchAttrib::Subject, nsMsgSearchOp::Isnt, 1);
aTable->SetAvailable (nsMsgSearchAttrib::Subject, nsMsgSearchOp::BeginsWith, 1);
aTable->SetEnabled (nsMsgSearchAttrib::Subject, nsMsgSearchOp::BeginsWith, 1);
aTable->SetAvailable (nsMsgSearchAttrib::Subject, nsMsgSearchOp::EndsWith, 1);
aTable->SetEnabled (nsMsgSearchAttrib::Subject, nsMsgSearchOp::EndsWith, 1);
aTable->SetAvailable (nsMsgSearchAttrib::Date, nsMsgSearchOp::IsBefore, 1);
aTable->SetEnabled (nsMsgSearchAttrib::Date, nsMsgSearchOp::IsBefore, 1);
aTable->SetAvailable (nsMsgSearchAttrib::Date, nsMsgSearchOp::IsAfter, 1);
aTable->SetEnabled (nsMsgSearchAttrib::Date, nsMsgSearchOp::IsAfter, 1);
aTable->SetAvailable (nsMsgSearchAttrib::Date, nsMsgSearchOp::Is, 1);
aTable->SetEnabled (nsMsgSearchAttrib::Date, nsMsgSearchOp::Is, 1);
aTable->SetAvailable (nsMsgSearchAttrib::Date, nsMsgSearchOp::Isnt, 1);
aTable->SetEnabled (nsMsgSearchAttrib::Date, nsMsgSearchOp::Isnt, 1);
aTable->SetAvailable (nsMsgSearchAttrib::AgeInDays, nsMsgSearchOp::IsGreaterThan, 1);
aTable->SetEnabled (nsMsgSearchAttrib::AgeInDays, nsMsgSearchOp::IsGreaterThan, 1);
aTable->SetAvailable (nsMsgSearchAttrib::AgeInDays, nsMsgSearchOp::IsLessThan, 1);
aTable->SetEnabled (nsMsgSearchAttrib::AgeInDays, nsMsgSearchOp::IsLessThan, 1);
aTable->SetAvailable (nsMsgSearchAttrib::AgeInDays, nsMsgSearchOp::Is, 1);
aTable->SetEnabled (nsMsgSearchAttrib::AgeInDays, nsMsgSearchOp::Is, 1);
aTable->SetAvailable (nsMsgSearchAttrib::MsgStatus, nsMsgSearchOp::Is, 1);
aTable->SetEnabled (nsMsgSearchAttrib::MsgStatus, nsMsgSearchOp::Is, 1);
aTable->SetAvailable (nsMsgSearchAttrib::MsgStatus, nsMsgSearchOp::Isnt, 1);
aTable->SetEnabled (nsMsgSearchAttrib::MsgStatus, nsMsgSearchOp::Isnt, 1);
aTable->SetAvailable (nsMsgSearchAttrib::Keywords, nsMsgSearchOp::Contains, 1);
aTable->SetEnabled (nsMsgSearchAttrib::Keywords, nsMsgSearchOp::Contains, 1);
aTable->SetAvailable (nsMsgSearchAttrib::Keywords, nsMsgSearchOp::DoesntContain, 1);
aTable->SetEnabled (nsMsgSearchAttrib::Keywords, nsMsgSearchOp::DoesntContain, 1);
aTable->SetAvailable (nsMsgSearchAttrib::Keywords, nsMsgSearchOp::Is, 1);
aTable->SetEnabled (nsMsgSearchAttrib::Keywords, nsMsgSearchOp::Is, 1);
aTable->SetAvailable (nsMsgSearchAttrib::Keywords, nsMsgSearchOp::Isnt, 1);
aTable->SetEnabled (nsMsgSearchAttrib::Keywords, nsMsgSearchOp::Isnt, 1);
aTable->SetAvailable (nsMsgSearchAttrib::Keywords, nsMsgSearchOp::IsEmpty, 1);
aTable->SetEnabled (nsMsgSearchAttrib::Keywords, nsMsgSearchOp::IsEmpty, 1);
aTable->SetAvailable (nsMsgSearchAttrib::Keywords, nsMsgSearchOp::IsntEmpty, 1);
aTable->SetEnabled (nsMsgSearchAttrib::Keywords, nsMsgSearchOp::IsntEmpty, 1);
aTable->SetAvailable (nsMsgSearchAttrib::OtherHeader, nsMsgSearchOp::Contains, 1);
aTable->SetEnabled (nsMsgSearchAttrib::OtherHeader, nsMsgSearchOp::Contains, 1);
aTable->SetAvailable (nsMsgSearchAttrib::OtherHeader, nsMsgSearchOp::DoesntContain, 1);
aTable->SetEnabled (nsMsgSearchAttrib::OtherHeader, nsMsgSearchOp::DoesntContain, 1);
aTable->SetAvailable (nsMsgSearchAttrib::OtherHeader, nsMsgSearchOp::Is, 1);
aTable->SetEnabled (nsMsgSearchAttrib::OtherHeader, nsMsgSearchOp::Is, 1);
aTable->SetAvailable (nsMsgSearchAttrib::OtherHeader, nsMsgSearchOp::Isnt, 1);
aTable->SetEnabled (nsMsgSearchAttrib::OtherHeader, nsMsgSearchOp::Isnt, 1);
aTable->SetAvailable (nsMsgSearchAttrib::OtherHeader, nsMsgSearchOp::BeginsWith, 1);
aTable->SetEnabled (nsMsgSearchAttrib::OtherHeader, nsMsgSearchOp::BeginsWith, 1);
aTable->SetAvailable (nsMsgSearchAttrib::OtherHeader, nsMsgSearchOp::EndsWith, 1);
aTable->SetEnabled (nsMsgSearchAttrib::OtherHeader, nsMsgSearchOp::EndsWith, 1);
return NS_OK;
}
nsresult nsMsgSearchValidityManager::InitLocalNewsTable()
{
NS_ASSERTION (nsnull == m_localNewsTable, "already have local news validity table");
nsresult rv = NewTable(getter_AddRefs(m_localNewsTable));
NS_ENSURE_SUCCESS(rv, rv);
return SetLocalNews(m_localNewsTable);
}
nsresult nsMsgSearchValidityManager::InitLocalNewsBodyTable()
{
NS_ASSERTION (nsnull == m_localNewsBodyTable, "already have local news+body validity table");
nsresult rv = NewTable(getter_AddRefs(m_localNewsBodyTable));
NS_ENSURE_SUCCESS(rv, rv);
rv = SetLocalNews(m_localNewsBodyTable);
NS_ENSURE_SUCCESS(rv, rv);
return SetBody(m_localNewsBodyTable);
}
nsresult nsMsgSearchValidityManager::InitLocalNewsJunkTable()
{
NS_ASSERTION (nsnull == m_localNewsJunkTable, "already have local news+junk validity table");
nsresult rv = NewTable(getter_AddRefs(m_localNewsJunkTable));
NS_ENSURE_SUCCESS(rv, rv);
rv = SetLocalNews(m_localNewsJunkTable);
NS_ENSURE_SUCCESS(rv, rv);
return SetJunk(m_localNewsJunkTable);
}
nsresult nsMsgSearchValidityManager::InitLocalNewsJunkBodyTable()
{
NS_ASSERTION (nsnull == m_localNewsJunkBodyTable, "already have local news+junk+body validity table");
nsresult rv = NewTable(getter_AddRefs(m_localNewsJunkBodyTable));
NS_ENSURE_SUCCESS(rv, rv);
rv = SetLocalNews(m_localNewsJunkBodyTable);
NS_ENSURE_SUCCESS(rv, rv);
rv = SetJunk(m_localNewsJunkBodyTable);
NS_ENSURE_SUCCESS(rv, rv);
return SetBody(m_localNewsJunkBodyTable);
}

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

@ -1049,6 +1049,28 @@ NS_IMETHODIMP nsMsgSearchValidityManager::GetTable (int whichTable, nsIMsgSearch
rv = SetOtherHeadersInTable(m_localNewsTable, customHeaders.get());
*ppOutTable = m_localNewsTable;
break;
case nsMsgSearchScope::localNewsJunk:
if (!m_localNewsJunkTable)
rv = InitLocalNewsJunkTable();
if (m_localNewsJunkTable)
rv = SetOtherHeadersInTable(m_localNewsJunkTable, customHeaders.get());
*ppOutTable = m_localNewsJunkTable;
break;
case nsMsgSearchScope::localNewsBody:
if (!m_localNewsBodyTable)
rv = InitLocalNewsBodyTable();
if (m_localNewsBodyTable)
rv = SetOtherHeadersInTable(m_localNewsBodyTable, customHeaders.get());
*ppOutTable = m_localNewsBodyTable;
break;
case nsMsgSearchScope::localNewsJunkBody:
if (!m_localNewsJunkBodyTable)
rv = InitLocalNewsJunkBodyTable();
if (m_localNewsJunkBodyTable)
rv = SetOtherHeadersInTable(m_localNewsJunkBodyTable, customHeaders.get());
*ppOutTable = m_localNewsJunkBodyTable;
break;
case nsMsgSearchScope::onlineManual:
if (!m_onlineManualFilterTable)
rv = InitOnlineManualFilterTable();

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

@ -1946,6 +1946,7 @@ nsresult nsMsgSearchScopeTerm::InitializeAdapter (nsISupportsArray *termList)
m_adapter = new nsMsgSearchOnlineMail (this, termList);
break;
case nsMsgSearchScope::offlineMail:
case nsMsgSearchScope::onlineManual:
m_adapter = new nsMsgSearchOfflineMail (this, termList);
break;
case nsMsgSearchScope::newsEx:
@ -1961,6 +1962,9 @@ nsresult nsMsgSearchScopeTerm::InitializeAdapter (nsISupportsArray *termList)
NS_ASSERTION(PR_FALSE, "not supporting LDAP yet");
break;
case nsMsgSearchScope::localNews:
case nsMsgSearchScope::localNewsJunk:
case nsMsgSearchScope::localNewsBody:
case nsMsgSearchScope::localNewsJunkBody:
m_adapter = new nsMsgSearchOfflineNews (this, termList);
break;
default:

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

@ -138,7 +138,7 @@ nsMsgSearchValueImpl::ToString(nsAString &aResult)
}
break;
default:
NS_ASSERTION(0, "Unknown search value type");
NS_ERROR("Unknown search value type");
}
aResult.AppendLiteral("]");

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

@ -169,6 +169,8 @@ nsMsgDBView::nsMsgDBView()
mGoBackEnabled = PR_FALSE;
mIsNews = PR_FALSE;
mIsRss = PR_FALSE;
mIsXFVirtual = PR_FALSE;
mDeleteModel = nsMsgImapDeleteModels::MoveToTrash;
m_deletingRows = PR_FALSE;
mNumMessagesRemainingInBatch = 0;
@ -1612,7 +1614,7 @@ NS_IMETHODIMP nsMsgDBView::GetCellValue(PRInt32 aRow, nsITreeColumn* aCol, nsASt
aValue.Adopt(GetString(NS_LITERAL_STRING("messageHasFlag").get()));
break;
case 'j': // junk column
if (!mIsNews)
if (JunkControlsEnabled(aRow))
{
nsCString junkScoreStr;
msgHdr->GetStringProperty("junkscore", getter_Copies(junkScoreStr));
@ -1986,7 +1988,7 @@ NS_IMETHODIMP nsMsgDBView::CycleCell(PRInt32 row, nsITreeColumn* col)
break;
case 'j': // junkStatus column
{
if (mIsNews) // junk not supported for news yet.
if (!JunkControlsEnabled(row))
return NS_OK;
nsCOMPtr <nsIMsgDBHdr> msgHdr;
@ -2073,8 +2075,20 @@ NS_IMETHODIMP nsMsgDBView::Open(nsIMsgFolder *folder, nsMsgViewSortTypeValue sor
rv = server->GetType(type);
NS_ENSURE_SUCCESS(rv,rv);
// I'm not sure this is correct, because XF virtual folders with mixed news
// and mail can have this set.
mIsNews = type.LowerCaseEqualsLiteral("nntp");
// Default to a virtual folder if folder not set, since synthetic search
// views may not have a folder.
PRUint32 folderFlags = nsMsgFolderFlags::Virtual;
if (folder)
folder->GetFlags(&folderFlags);
mIsXFVirtual = folderFlags & nsMsgFolderFlags::Virtual;
if (!mIsXFVirtual && type.LowerCaseEqualsLiteral("rss"))
mIsRss = PR_TRUE;
if (type.IsEmpty())
mMessageTypeAtom = nsnull;
else // special case nntp --> news since we'll break themes if we try to be consistent
@ -2457,7 +2471,8 @@ NS_IMETHODIMP nsMsgDBView::GetCommandStatus(nsMsgViewCommandTypeValue command, P
if (mTreeSelection && NS_SUCCEEDED(mTreeSelection->GetRangeCount(&rangeCount)) && rangeCount > 0)
haveSelection = NonDummyMsgSelected(indices, numIndices);
else
haveSelection = PR_FALSE;
// If we don't have a tree selection we must be in stand alone mode.
haveSelection = m_currentlyDisplayedViewIndex != nsMsgViewIndex_None;
switch (command)
{
@ -2482,9 +2497,8 @@ NS_IMETHODIMP nsMsgDBView::GetCommandStatus(nsMsgViewCommandTypeValue command, P
break;
case nsMsgViewCommandType::runJunkControls:
// disable if no messages
// no JMC on news yet
// XXX todo, check that we have JMC enabled?
*selectable_p = GetSize() && !mIsNews;
*selectable_p = GetSize() && JunkControlsEnabled(nsMsgViewIndex_None);
break;
case nsMsgViewCommandType::deleteJunk:
{
@ -2505,7 +2519,7 @@ NS_IMETHODIMP nsMsgDBView::GetCommandStatus(nsMsgViewCommandTypeValue command, P
break;
case nsMsgViewCommandType::junk:
case nsMsgViewCommandType::unjunk:
*selectable_p = haveSelection && !mIsNews; // no junk for news yet
*selectable_p = haveSelection && JunkControlsEnabled(selection[0]);
break;
case nsMsgViewCommandType::cmdRequiringMsgBody:
*selectable_p = haveSelection && (!WeAreOffline() || OfflineMsgSelected(indices, numIndices));
@ -3764,7 +3778,7 @@ nsresult nsMsgDBView::GetLongField(nsIMsgDBHdr *msgHdr, nsMsgViewSortTypeValue s
case nsMsgViewSortType::byId:
// handled by caller, since caller knows the key
default:
NS_ASSERTION(0,"should not be here");
NS_ERROR("should not be here");
rv = NS_ERROR_UNEXPECTED;
break;
}
@ -4242,7 +4256,7 @@ NS_IMETHODIMP nsMsgDBView::Sort(nsMsgViewSortTypeValue sortType, nsMsgViewSortOr
NS_QuickSort(pPtrBase, numSoFar, sizeof(IdKey*), FnSortIdUint32, &qsPrivateData);
break;
default:
NS_ASSERTION(0, "not supposed to get here");
NS_ERROR("not supposed to get here");
break;
}
}
@ -5772,7 +5786,7 @@ NS_IMETHODIMP nsMsgDBView::SetSortType(nsMsgViewSortTypeValue aSortType)
NS_IMETHODIMP nsMsgDBView::GetViewType(nsMsgViewTypeValue *aViewType)
{
NS_ASSERTION(0,"you should be overriding this\n");
NS_ERROR("you should be overriding this");
return NS_ERROR_UNEXPECTED;
}
@ -6183,7 +6197,7 @@ nsresult nsMsgDBView::NavigateFromPos(nsMsgNavigationTypeValue motion, nsMsgView
}
default:
NS_ASSERTION(0, "unsupported motion");
NS_ERROR("unsupported motion");
break;
}
return NS_OK;
@ -6274,7 +6288,7 @@ NS_IMETHODIMP nsMsgDBView::NavigateStatus(nsMsgNavigationTypeValue motion, PRBoo
break;
default:
NS_ASSERTION(0,"unexpected");
NS_ERROR("unexpected");
break;
}
@ -6343,7 +6357,7 @@ nsresult nsMsgDBView::FindPrevUnread(nsMsgKey startKey, nsMsgKey *pResultKey,
if (curIndex != startIndex && flags & MSG_VIEW_FLAG_ISTHREAD && flags & nsMsgMessageFlags::Elided)
{
NS_ASSERTION(0,"fix this");
NS_ERROR("fix this");
//nsMsgKey threadId = m_keys[curIndex];
//rv = m_db->GetUnreadKeyInThread(threadId, pResultKey, resultThreadId);
if (NS_SUCCEEDED(rv) && (*pResultKey != nsMsgKey_None))
@ -7135,6 +7149,8 @@ nsresult nsMsgDBView::CopyDBView(nsMsgDBView *aNewMsgDBView, nsIMessenger *aMess
if (m_db)
aNewMsgDBView->m_db->AddListener(aNewMsgDBView);
aNewMsgDBView->mIsNews = mIsNews;
aNewMsgDBView->mIsRss = mIsRss;
aNewMsgDBView->mIsXFVirtual = mIsXFVirtual;
aNewMsgDBView->mShowSizeInLines = mShowSizeInLines;
aNewMsgDBView->mHeaderParser = mHeaderParser;
aNewMsgDBView->mDeleteModel = mDeleteModel;
@ -7297,3 +7313,46 @@ nsresult nsMsgDBView::GetViewEnumerator(nsISimpleEnumerator **enumerator)
NS_IF_ADDREF(*enumerator = new nsMsgViewHdrEnumerator(this));
return (*enumerator) ? NS_OK : NS_ERROR_OUT_OF_MEMORY;
}
/**
* Determine whether junk commands should be enabled on this view.
* Junk commands are always enabled for mail. For nntp and rss, they
* may be selectively enabled using an inherited folder property.
*
* @param aViewIndex view index of the message to check
* @return PR_TRUE if junk controls should be enabled
*/
PRBool nsMsgDBView::JunkControlsEnabled(nsMsgViewIndex aViewIndex)
{
// For normal mail, junk commands are always enabled.
if (!(mIsNews || mIsRss || mIsXFVirtual))
return PR_TRUE;
// we need to check per message or folder
nsCOMPtr <nsIMsgFolder> folder = m_folder;
if (!folder && aViewIndex != nsMsgViewIndex_None)
GetFolderForViewIndex(aViewIndex, getter_AddRefs(folder));
if (folder)
{
// Check if this is a mail message in search folders.
if (mIsXFVirtual)
{
nsCOMPtr <nsIMsgIncomingServer> server;
folder->GetServer(getter_AddRefs(server));
nsCAutoString type;
if (server)
server->GetType(type);
if (!(type.LowerCaseEqualsLiteral("nntp") || type.LowerCaseEqualsLiteral("rss")))
return PR_TRUE;
}
// For rss and news, check the inherited folder property.
nsCAutoString junkEnableOverride;
folder->GetInheritedStringProperty("dobayes.mailnews@mozilla.org#junk",
junkEnableOverride);
if (junkEnableOverride.EqualsLiteral("true"))
return PR_TRUE;
}
return PR_FALSE;
}

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

@ -379,6 +379,8 @@ protected:
nsresult DownloadForOffline(nsIMsgWindow *window, nsMsgViewIndex *indices, PRInt32 numIndices);
nsresult DownloadFlaggedForOffline(nsIMsgWindow *window);
nsMsgViewIndex GetThreadFromMsgIndex(nsMsgViewIndex index, nsIMsgThread **threadHdr);
/// Should junk commands be enabled for the current message in the view?
PRBool JunkControlsEnabled(nsMsgViewIndex aViewIndex);
// for sorting
nsresult GetFieldTypeAndLenForSort(nsMsgViewSortTypeValue sortType, PRUint16 *pMaxLen, eFieldType *pFieldType);
@ -445,7 +447,12 @@ protected:
// and decendents of those folders
// (like the "Sent" folder, "Sent/Old Sent")
// the Sender column really shows recipients.
// Server types for this view's folder
PRPackedBool mIsNews; // we have special icons for news
PRPackedBool mIsRss; // rss affects enabling of junk commands
PRPackedBool mIsXFVirtual; // a virtual folder with multiple folders
PRPackedBool mShowSizeInLines; // for news we show lines instead of size when true
PRPackedBool m_sortValid;
PRPackedBool mSelectionSummarized;

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

@ -396,8 +396,9 @@ NS_IMETHODIMP nsMsgMailSession::RemoveMsgWindow(nsIMsgWindow *msgWindow)
mWindows.RemoveObject(msgWindow);
// Mac keeps a hidden window open so the app doesn't shut down when
// the last window is closed. So don't shutdown the account manager in that
// case.
#ifndef XP_MACOSX
// case. Similarly, for suite, we don't want to disable mailnews when the
// last mail window is closed.
#if !defined(XP_MACOSX) && !defined(MOZ_SUITE)
if (!mWindows.Count())
{
nsresult rv;

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

@ -380,42 +380,54 @@ SearchSpec.prototype = {
return;
}
// We are filtering if we have mail view terms or user terms. When
// filtering, we bias towards offline search. The only time we would use
// an online search when filtering is if one of the constraints uses the
// body attribute and the folder is not marked for offline access.
// We are not filtering if we only have virtual folder terms, in which case
// we honor the onlineSearch attribute. This means that we use the
// folder's server's searchScope if the folder is not explicitly marked
// offline.
// For further discussion on this choice of logic, please read from:
// https://bugzilla.mozilla.org/show_bug.cgi?id=474701#c73
let filtering = this._virtualFolderTerms == null &&
this._viewTerms == null;
let ioService = Cc["@mozilla.org/network/io-service;1"]
.getService(Ci.nsIIOService);
let validityManager = Cc['@mozilla.org/mail/search/validityManager;1']
.getService(Ci.nsIMsgSearchValidityManager);
for each (let [, folder] in Iterator(this.owner._underlyingFolders)) {
// we do not need to check isServer here because _underlyingFolders
// filtered it out when it was initialized.
let scope;
let folderIsOffline = (folder instanceof nsIMsgLocalMailFolder) ||
(folder.flags & nsMsgFolderFlags.Offline) ||
ioService.offline;
// To restate the above logic into simpler rules, the scope is definitely
// offline if:
// - Folders available offline always use offline search.
// - If we are filtering and don't have a body term, use offline search.
// - If we are not filtering and our virtual folder is not marked for
// onlineSearch.
if (folderIsOffline ||
(filtering && !haveBodyTerm) ||
(!filtering && !this.onlineSearch))
scope = nsMsgSearchScope.offlineMail;
// Otherwise, it's up to the folder's sever's searchScope.
else
scope = folder.server.searchScope;
let serverScope = folder.server.searchScope;
// If we're offline, or this is a local folder, or there's no separate
// online scope, use server scope.
if (ioService.offline || (serverScope == nsMsgSearchScope.offlineMail) ||
(folder instanceof nsIMsgLocalMailFolder))
scope = serverScope;
else {
// we need to test the validity in online and offline tables
let onlineValidityTable = validityManager.getTable(serverScope);
let offlineScope;
if (folder.flags & nsMsgFolderFlags.Offline)
offlineScope = nsMsgSearchScope.offlineMail;
else
// The onlineManual table is used for local search when there is no
// body available.
offlineScope = nsMsgSearchScope.onlineManual;
let offlineValidityTable = validityManager.getTable(offlineScope);
let offlineAvailable = true;
let onlineAvailable = true;
for each (let term in fixIterator(session.searchTerms,
nsIMsgSearchTerm)) {
if (!term.matchAll) {
if (!offlineValidityTable.getAvailable(term.attrib, term.op))
offlineAvailable = false;
if (!onlineValidityTable.getAvailable(term.attrib, term.op))
onlineAvailable = false;
}
}
// If both scopes work, honor the onlineSearch request
if (onlineAvailable && offlineAvailable)
scope = this.onlineSearch ? serverScope : offlineScope;
// If only one works, use it. Otherwise, default to offline
else if (onlineAvailable)
scope = serverScope;
else
scope = offlineScope;
}
session.addScopeTerm(scope, folder);
}
},

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

@ -340,7 +340,7 @@ nsMsgI18NParseMetaCharset(nsILocalFile* file)
PRBool isDirectory = PR_FALSE;
file->IsDirectory(&isDirectory);
if (isDirectory) {
NS_ASSERTION(0,"file is a directory");
NS_ERROR("file is a directory");
return charset;
}

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

@ -761,11 +761,9 @@ NS_IMETHODIMP
nsMsgIncomingServer::GetPasswordWithUI(const nsAString& aPromptMessage, const
nsAString& aPromptTitle,
nsIMsgWindow* aMsgWindow,
PRBool *okayValue,
nsACString& aPassword)
{
nsresult rv = NS_OK;
NS_ENSURE_ARG_POINTER(okayValue);
if (m_password.IsEmpty())
{
@ -818,16 +816,17 @@ nsMsgIncomingServer::GetPasswordWithUI(const nsAString& aPromptMessage, const
if (!aPassword.IsEmpty())
uniPassword = ToNewUnicode(NS_ConvertASCIItoUTF16(aPassword));
PRBool okayValue = PR_TRUE;
rv = dialog->PromptPassword(PromiseFlatString(aPromptTitle).get(),
PromiseFlatString(aPromptMessage).get(),
NS_ConvertASCIItoUTF16(serverUri).get(),
nsIAuthPrompt::SAVE_PASSWORD_PERMANENTLY,
&uniPassword, okayValue);
&uniPassword, &okayValue);
nsAutoString uniPasswordAdopted;
uniPasswordAdopted.Adopt(uniPassword);
NS_ENSURE_SUCCESS(rv, rv);
if (!*okayValue) // if the user pressed cancel, just return an empty string;
if (!okayValue) // if the user pressed cancel, just return an empty string;
{
aPassword.Truncate();
return NS_MSG_PASSWORD_PROMPT_CANCELLED;

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

@ -23,6 +23,7 @@
* Ben Bucksch <mozilla.BenB@bucksch.org>
* Ian Neal <bugzilla@arlen.demon.co.uk>
* Žiga Sancin <bisi@pikslar.com>
* Magnus Melin <mkmelin+mozilla@iki.fi>
*
* Alternatively, the contents of this file may be used under the terms of
* either of the GNU General Public License Version 2 or later (the "GPL"),
@ -38,153 +39,57 @@
*
* ***** END LICENSE BLOCK ***** */
var msgCompSendFormat = Components.interfaces.nsIMsgCompSendFormat;
var msgCompConvertible = Components.interfaces.nsIMsgCompConvertible;
var param = null;
/* There are 3 preferences that let you customize the behavior of this dialog
1. pref("mail.asksendformat.default", 1); //1=plaintext, 2=html, 3=both
This defines the default action selected when the dialog opens. It can be overwritten by the preference
mail.asksendformat.recommended_as_default
2. pref("mail.asksendformat.recommended_as_default", true);
If you set this preference to true and we have a recommended action, this action will be selected by default.
In this case, we ignore the preference mail.asksendformat.default
3. pref("mail.asksendformat.display_recommendation", true);
When this preference is set to false, the recommended action label will not be displayed next to the action
radio button. However, the default action might change to the recommended one if the preference
mail.asksendformat.recommended_as_default is set.
*/
var defaultAction = msgCompSendFormat.PlainText;
var recommended_as_default = true;
var display_recommendation = true;
var useDefault = false;
var prefs = Components.classes["@mozilla.org/preferences-service;1"].getService();
if (prefs)
{
prefs = prefs.QueryInterface(Components.interfaces.nsIPrefBranch);
if (prefs)
{
try
{
defaultAction = prefs.getIntPref("mail.asksendformat.default");
useDefault = true;
}
catch (ex) {}
try
{
recommended_as_default = prefs.getBoolPref("mail.asksendformat.recommended_as_default");
}
catch (ex) {}
try
{
display_recommendation = prefs.getBoolPref("mail.asksendformat.display_recommendation");
}
catch (ex) {}
}
}
var gParam = null;
/**
* This dialog should be opened with arguments like e.g.
* {action: nsIMsgCompSendFormat.AskUser, convertible: nsIMsgCompConvertible.Yes}
*/
function Startup()
{
if (window.arguments && window.arguments[0])
gParam = window.arguments[0];
const msgCompSendFormat = Components.interfaces.nsIMsgCompSendFormat;
const msgCompConvertible = Components.interfaces.nsIMsgCompConvertible;
var bundle = document.getElementById("askSendFormatStringBundle");
// If the user hits the close box, we will abort.
gParam.abort = true;
// Set the question label
var mailSendFormatExplanation = document.getElementById("mailSendFormatExplanation");
var icon = document.getElementById("convertDefault");
switch (gParam.convertible)
{
var askSendFormatStringBundle = document.getElementById("askSendFormatStringBundle");
param = window.arguments[0];
// If the user hits the close box, we will abort.
param.abort = true;
if (param.action)
{
// Set the question label
var mailSendFormatExplanation = document.getElementById("mailSendFormatExplanation");
var icon = document.getElementById("convertDefault");
switch (param.convertible)
{
case msgCompConvertible.Plain:
// We shouldn't be here at all
mailSendFormatExplanation.textContent = askSendFormatStringBundle.getString("convertibleYes");
// No icon
break;
case msgCompConvertible.Yes:
mailSendFormatExplanation.textContent = askSendFormatStringBundle.getString("convertibleYes");
icon.setAttribute("id", "convertYes");
break;
case msgCompConvertible.Altering:
mailSendFormatExplanation.textContent = askSendFormatStringBundle.getString("convertibleAltering");
icon.setAttribute("id", "convertAltering");
break;
case msgCompConvertible.No:
mailSendFormatExplanation.textContent = askSendFormatStringBundle.getString("convertibleNo");
icon.setAttribute("id", "convertNo");
break;
}
// Set the default radio array value and recommendation
var group = document.getElementById("mailDefaultHTMLAction");
var radio;
var radioButtons = group.getElementsByTagName("radio");
var haveRecommendation = false;
var format = (useDefault) ? defaultAction : param.action;
switch (format)
{
case msgCompSendFormat.AskUser:
// haveRecommendation = false;
break;
case msgCompSendFormat.PlainText:
radio = radioButtons[1];
haveRecommendation = true;
break;
case msgCompSendFormat.Both:
radio = radioButtons[0];
haveRecommendation = true;
break;
case msgCompSendFormat.HTML:
radio = radioButtons[2];
haveRecommendation = true;
break;
}
if (haveRecommendation)
{
if (display_recommendation)
radio.label += " " + askSendFormatStringBundle.getString("recommended");
if (recommended_as_default)
group.value = format;
}
if (!haveRecommendation || !recommended_as_default)
group.value = defaultAction;
}
case msgCompConvertible.Altering:
mailSendFormatExplanation.textContent = bundle.getString("convertibleAltering");
icon.className = "question-icon";
break;
case msgCompConvertible.No:
mailSendFormatExplanation.textContent = bundle.getString("convertibleNo");
icon.className = "alert-icon";
break;
default: // msgCompConvertible.Yes
mailSendFormatExplanation.textContent = bundle.getString("convertibleYes");
// XXX change this to use class message-icon once bug 512173 is fixed
icon.className = "question-icon";
break;
}
else
// Set the default radio array value and recommendation.
var group = document.getElementById("mailDefaultHTMLAction");
if (gParam.action != msgCompSendFormat.AskUser)
{
dump("error, no return object registered\n");
group.value = gParam.action;
group.selectedItem.label += " " + bundle.getString("recommended");
}
}
function Send()
{
if (param)
{
// param.action should be an integer for when it is returned to MsgComposeCommands.js
param.action = parseInt(document.getElementById("mailDefaultHTMLAction").value);
param.abort = false;
}
return true;
}
function Cancel()
{
if (param)
param.abort = true;
return true;
// gParam.action should be an integer for when it is returned to MsgComposeCommands.js
gParam.action = parseInt(document.getElementById("mailDefaultHTMLAction").value);
gParam.abort = false;
}

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

@ -39,7 +39,7 @@
-
- ***** END LICENSE BLOCK ***** -->
<?xml-stylesheet href="chrome://messenger/skin/dialogs.css" type="text/css"?>
<?xml-stylesheet href="chrome://global/skin/global.css" type="text/css"?>
<!DOCTYPE dialog SYSTEM "chrome://messenger/locale/messengercompose/askSendFormat.dtd">
@ -48,10 +48,10 @@
xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"
buttonpack="center"
onload="Startup();"
ondialogaccept="return Send();"
ondialogcancel="return Cancel();"
ondialogaccept="Send();"
buttonlabelaccept="&send.label;"
buttonaccesskeyaccept="&send.accesskey;">
buttonaccesskeyaccept="&send.accesskey;"
style="width: 75ch;">
<script type="application/javascript"
src="chrome://messenger/content/messengercompose/askSendFormat.js"/>
@ -73,7 +73,8 @@
<separator/>
<radiogroup id="mailDefaultHTMLAction">
<radio value="3" label="&plainTextAndHtml.label;" accesskey="&plainTextAndHtml.accesskey;"/>
<radio value="1" label="&plainTextOnly.label;" accesskey="&plainTextOnly.accesskey;"/>
<radio value="1" selected="true"
label="&plainTextOnly.label;" accesskey="&plainTextOnly.accesskey;"/>
<radio value="2" label="&htmlOnly.label;" accesskey="&htmlOnly.accesskey;"/>
</radiogroup>
</vbox>

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

@ -248,7 +248,7 @@ NS_IMETHODIMP nsMsgCompFields::GetSubject(nsAString &_retval)
NS_IMETHODIMP nsMsgCompFields::SetTemporaryFiles(const char *value)
{
NS_ASSERTION(0, "nsMsgCompFields::SetTemporaryFiles is not supported anymore, please use nsMsgCompFields::AddAttachment");
NS_ERROR("nsMsgCompFields::SetTemporaryFiles is not supported anymore, please use nsMsgCompFields::AddAttachment");
return SetAsciiHeader(MSG_TEMPORARY_FILES_HEADER_ID, value);
}

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

@ -151,12 +151,12 @@ public:
const char* GetSubject() {return GetAsciiHeader(MSG_SUBJECT_HEADER_ID);}
const char* GetAttachments() {
NS_ASSERTION(0, "nsMsgCompFields::GetAttachments is not supported anymore, please use nsMsgCompFields::GetAttachmentsArray");
NS_ERROR("nsMsgCompFields::GetAttachments is not supported anymore, please use nsMsgCompFields::GetAttachmentsArray");
return GetAsciiHeader(MSG_ATTACHMENTS_HEADER_ID);
}
const char* GetTemporaryFiles() {
NS_ASSERTION(0, "nsMsgCompFields::GetTemporaryFiles is not supported anymore, please use nsMsgCompFields::GetAttachmentsArray");
NS_ERROR("nsMsgCompFields::GetTemporaryFiles is not supported anymore, please use nsMsgCompFields::GetAttachmentsArray");
return GetAsciiHeader(MSG_TEMPORARY_FILES_HEADER_ID);
}

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

@ -3837,7 +3837,7 @@ nsMsgCompose::LoadDataFromFile(nsILocalFile *file, nsString &sigData,
PRBool isDirectory = PR_FALSE;
file->IsDirectory(&isDirectory);
if (isDirectory) {
NS_ASSERTION(0,"file is a directory");
NS_ERROR("file is a directory");
return NS_MSG_ERROR_READING_FILE;
}

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

@ -3662,7 +3662,7 @@ nsMsgComposeAndSend::DeliverFileAsMail()
else if (!forcePlainText)
sendFormat = nsIAbPreferMailFormat::html;
else
NS_ASSERTION(0,"unknown send format, should not happen");
NS_ERROR("unknown send format, should not happen");
#endif
PL_strcpy (buf, "");

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

@ -136,7 +136,7 @@ NS_IMETHODIMP nsImapMailDatabase::GetFolderStream(nsIOutputStream **aFileStream)
NS_IMETHODIMP nsImapMailDatabase::SetFolderStream(nsIOutputStream *aFileStream)
{
NS_ASSERTION(0, "Trying to set folderStream, not implemented");
NS_ERROR("Trying to set folderStream, not implemented");
return NS_ERROR_NOT_IMPLEMENTED;
}

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

@ -5348,7 +5348,7 @@ NS_IMETHODIMP nsMsgDatabase::GetFolderStream(nsIOutputStream **aFileStream)
NS_IMETHODIMP nsMsgDatabase::SetFolderStream(nsIOutputStream *aFileStream)
{
NS_ASSERTION(0, "Trying to set the folderStream, not implemented");
NS_ERROR("Trying to set the folderStream, not implemented");
return NS_ERROR_NOT_IMPLEMENTED;
}

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

@ -47,17 +47,13 @@ var gBrandBundle;
var gSMFields;
var gEncryptedURIService = null;
function onComposerClose()
{
gSMFields = null;
setNoEncryptionUI();
setNoSignatureUI();
if (!gMsgCompose)
return;
if (!gMsgCompose.compFields)
if (!gMsgCompose || !gMsgCompose.compFields)
return;
gMsgCompose.compFields.securityInfo = null;
@ -65,14 +61,8 @@ function onComposerClose()
function onComposerReOpen()
{
// are we already set up?
if (gSMFields)
return;
if (!gMsgCompose)
return;
if (!gMsgCompose.compFields)
// Are we already set up ? Or are the required fields missing ?
if (gSMFields || !gMsgCompose || !gMsgCompose.compFields)
return;
gMsgCompose.compFields.securityInfo = null;
@ -98,57 +88,69 @@ function onComposerReOpen()
}
if (gSMFields.requireEncryptMessage)
{
setEncryptionUI();
}
else
{
setNoEncryptionUI();
}
if (gSMFields.signMessage)
{
setSignatureUI();
}
else
{
setNoSignatureUI();
}
}
}
addEventListener("load", smimeComposeOnLoad, false);
// this function gets called multiple times,
// but only on first open, not on composer recycling
function smimeComposeOnLoad()
{
removeEventListener("load", smimeComposeOnLoad, false);
if (!gEncryptedURIService)
{
gEncryptedURIService =
Components.classes["@mozilla.org/messenger-smime/smime-encrypted-uris-service;1"]
.getService(Components.interfaces.nsIEncryptedSMIMEURIsService);
}
onComposerReOpen();
top.controllers.appendController(SecurityController);
addEventListener("compose-from-changed", onComposerFromChanged, true);
addEventListener("compose-send-message", onComposerSendMessage, true);
addEventListener("compose-window-close", onComposerClose, true);
addEventListener("compose-window-reopen", onComposerReOpen, true);
addEventListener("unload", smimeComposeOnUnload, false);
}
function smimeComposeOnUnload()
{
removeEventListener("unload", smimeComposeOnUnload, false);
removeEventListener("compose-from-changed", onComposerFromChanged, true);
removeEventListener("compose-send-message", onComposerSendMessage, true);
removeEventListener("compose-window-close", onComposerClose, true);
removeEventListener("compose-window-reopen", onComposerReOpen, true);
top.controllers.removeController(SecurityController);
}
function setupBundles()
{
if (gBundle && gBrandBundle)
if (gBundle)
return;
if (!gBundle) {
gBundle = document.getElementById("bundle_comp_smime");
gBrandBundle = document.getElementById("bundle_brand");
}
gBundle = document.getElementById("bundle_comp_smime");
gBrandBundle = document.getElementById("bundle_brand");
}
function showNeedSetupInfo()
{
var ifps = Components.interfaces.nsIPromptService;
var promptService = Components.classes["@mozilla.org/embedcomp/prompt-service;1"].getService();
promptService = promptService.QueryInterface(ifps);
let promptService = Components.classes["@mozilla.org/embedcomp/prompt-service;1"]
.getService(ifps);
setupBundles();
if (promptService && gBundle && gBrandBundle) {
@ -260,7 +262,6 @@ function doSecurityButton()
case "show":
default:
showMessageComposeSecurityStatus();
break;
}
}
@ -320,7 +321,7 @@ var SecurityController =
default:
return false;
}
}
},
isCommandEnabled: function(command)
@ -328,29 +329,25 @@ var SecurityController =
switch ( command )
{
case "cmd_viewSecurityStatus":
{
return true;
}
default:
return false;
}
return false;
}
};
function onComposerSendMessage()
{
let missingCount = new Object();
let emailAddresses = new Object();
try {
if (!gMsgCompose.compFields.securityInfo.requireEncryptMessage) {
return;
}
var helper = Components.classes[gSMimeContractID].createInstance(gISMimeJSHelper);
var emailAddresses = new Object();
var missingCount = new Object();
helper.getNoCertAddresses(
gMsgCompose.compFields,
missingCount,
@ -376,20 +373,17 @@ function onComposerSendMessage()
// Try the global one
var prefs = Components.classes["@mozilla.org/preferences-service;1"]
.getService(Components.interfaces.nsIPrefBranch);
if (prefs.getBoolPref("ldap_2.autoComplete.useDirectory"))
autocompleteDirectory =
prefs.getCharPref("ldap_2.autoComplete.directoryServer");
}
if (autocompleteDirectory)
{
window.openDialog('chrome://messenger-smime/content/certFetchingStatus.xul',
'',
'chrome,resizable=1,modal=1,dialog=1',
autocompleteDirectory,
emailAddresses.value);
}
}
}
@ -427,9 +421,3 @@ function onComposerFromChanged()
}
}
}
top.controllers.appendController(SecurityController);
addEventListener('compose-window-close', onComposerClose, true);
addEventListener('compose-window-reopen', onComposerReOpen, true);
addEventListener('compose-send-message', onComposerSendMessage, true);
addEventListener('compose-from-changed', onComposerFromChanged, true);

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

@ -45,10 +45,7 @@
<overlay xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul">
<script type="application/x-javascript" src="chrome://messenger-smime/content/msgCompSMIMEOverlay.js"/>
<script type="application/x-javascript"><![CDATA[
window.addEventListener("load", smimeComposeOnLoad, true);
]]></script>
<script type="application/javascript" src="chrome://messenger-smime/content/msgCompSMIMEOverlay.js"/>
<window id="msgcomposeWindow">
<broadcaster id="securityStatus" crypto="" signing=""/>

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

@ -45,23 +45,37 @@ var gBrandBundle;
const nsPKIParamBlock = "@mozilla.org/security/pkiparamblock;1";
const nsIPKIParamBlock = Components.interfaces.nsIPKIParamBlock;
addEventListener("load", smimeReadOnLoad, false);
function smimeReadOnLoad()
{
removeEventListener("load", smimeReadOnLoad, false);
top.controllers.appendController(SecurityController);
addEventListener("unload", smimeReadOnUnload, false);
}
function smimeReadOnUnload()
{
removeEventListener("unload", smimeReadOnUnload, false);
top.controllers.removeController(SecurityController);
}
function setupBundles()
{
if (gBundle && gBrandBundle)
if (gBundle)
return;
if (!gBundle) {
gBundle = document.getElementById("bundle_read_smime");
gBrandBundle = document.getElementById("bundle_brand");
}
gBundle = document.getElementById("bundle_read_smime");
gBrandBundle = document.getElementById("bundle_brand");
}
function showImapSignatureUnknown()
{
var ifps = Components.interfaces.nsIPromptService;
var promptService = Components.classes["@mozilla.org/embedcomp/prompt-service;1"].getService();
promptService = promptService.QueryInterface(ifps);
let promptService = Components.classes["@mozilla.org/embedcomp/prompt-service;1"]
.getService(Components.interfaces.nsIPromptService);
setupBundles();
if (promptService && gBundle && gBrandBundle) {
@ -110,7 +124,7 @@ var SecurityController =
default:
return false;
}
}
},
isCommandEnabled: function(command)
@ -118,7 +132,6 @@ var SecurityController =
switch ( command )
{
case "cmd_viewSecurityStatus":
{
if (document.documentElement.getAttribute('windowtype') == "mail:messageWindow")
{
return (GetNumSelectedMessages() > 0);
@ -134,14 +147,10 @@ var SecurityController =
return enabled.value;
}
}
return false;
}
// else: fall through.
default:
return false;
}
return false;
}
};
top.controllers.appendController(SecurityController);

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

@ -2146,7 +2146,6 @@ NS_IMETHODIMP nsImapIncomingServer::PromptForPassword(nsACString& aPassword,
nsString passwordTitle;
IMAPGetStringByID(IMAP_ENTER_PASSWORD_PROMPT_TITLE, getter_Copies(passwordTitle));
nsCString promptValue;
PRBool okayValue;
GetRealUsername(promptValue);
nsCString hostName;
@ -2159,9 +2158,7 @@ NS_IMETHODIMP nsImapIncomingServer::PromptForPassword(nsACString& aPassword,
IMAP_ENTER_PASSWORD_PROMPT,
passwordText);
NS_ENSURE_SUCCESS(rv,rv);
rv = GetPasswordWithUI(passwordText, passwordTitle, aMsgWindow,
&okayValue, aPassword);
return (okayValue) ? rv : NS_MSG_PASSWORD_PROMPT_CANCELLED;
return GetPasswordWithUI(passwordText, passwordTitle, aMsgWindow, aPassword);
}
// for the nsIImapServerSink interface

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

@ -1763,7 +1763,7 @@ NS_IMETHODIMP nsImapMailFolder::RenameLocal(const nsACString& newName, nsIMsgFol
if (!isDirectory)
parentPathFile->Create(nsIFile::DIRECTORY_TYPE, 0700);
else
NS_ASSERTION(0,"Directory already exists.");
NS_ERROR("Directory already exists.");
rv = RecursiveCopy(dirFile, parentPathFile);
NS_ENSURE_SUCCESS(rv,rv);
dirFile->Remove(PR_TRUE); // moving folders

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

@ -6973,9 +6973,15 @@ void nsImapProtocol::DiscoverMailboxList()
if (hasXLIST && usingSubscription)
{
m_hierarchyNameState = kXListing;
// We use "%.%" since gmail special folders are unlikely
nsCAutoString pattern("%");
List("%", PR_TRUE, PR_TRUE);
// We list the first and second levels since special folders are unlikely
// to be more than 2 levels deep.
List("%.%", PR_TRUE, PR_TRUE);
char separator = 0;
m_runningUrl->GetOnlineSubDirSeparator(&separator);
pattern.Append(separator);
pattern += '%';
List(pattern.get(), PR_TRUE, PR_TRUE);
}
SetMailboxDiscoveryStatus(eContinue);
@ -7932,8 +7938,10 @@ nsresult nsImapProtocol::GetPassword(nsCString &password)
// GetPasswordWithUI will truncate the password.
nsCString pwd = m_lastPasswordSent;
nsresult rv = m_imapServerSink->PromptForPassword(pwd, msgWindow);
if (rv == NS_MSG_PASSWORD_PROMPT_CANCELLED)
if (NS_FAILED(rv) || rv == NS_MSG_PASSWORD_PROMPT_CANCELLED)
return NS_ERROR_ABORT;
password.Assign(pwd);
}
m_lastPasswordSent = password;

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

@ -698,7 +698,7 @@ nsresult nsImapService::FetchMimePart(nsIImapUrl *aImapUrl,
// or stream listener passed into us in this method but i'm not sure yet...
// I'm going to use an assert for now to figure out if this is ever getting called
#if defined(DEBUG_mscott) || defined(DEBUG_bienvenu)
NS_ASSERTION(0, "oops...someone still is reaching this part of the code");
NS_ERROR("oops...someone still is reaching this part of the code");
#endif
rv = GetImapConnectionAndLoadUrl(NS_GetCurrentThread(), aImapUrl,
aDisplayConsumer, aURL);
@ -1137,7 +1137,7 @@ nsresult nsImapService::GetMessageFromUrl(nsIImapUrl *aImapUrl,
// or stream listener passed into us in this method but i'm not sure yet...
// I'm going to use an assert for now to figure out if this is ever getting called
#if defined(DEBUG_mscott) || defined(DEBUG_bienvenu)
NS_ASSERTION(0, "oops...someone still is reaching this part of the code");
NS_ERROR("oops...someone still is reaching this part of the code");
#endif
rv = GetImapConnectionAndLoadUrl(NS_GetCurrentThread(), aImapUrl,
aDisplayConsumer, aURL);

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

@ -1658,7 +1658,7 @@ nsMsgLocalMailFolder::CopyMessages(nsIMsgFolder* srcFolder, nsIArray*
nsresult rv = GetIsServer(&isServer);
if (NS_SUCCEEDED(rv) && isServer)
{
NS_ASSERTION(0, "Destination is the root folder. Cannot move/copy here");
NS_ERROR("Destination is the root folder. Cannot move/copy here");
if (isMove)
srcFolder->NotifyFolderEvent(mDeleteOrMoveMsgFailedAtom);
return OnCopyCompleted(srcSupport, PR_FALSE);

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

@ -663,7 +663,7 @@ void nsPop3Protocol::SetUsername(const char* name)
m_username = name;
}
nsresult nsPop3Protocol::GetPassword(nsCString& aPassword, PRBool *okayValue)
nsresult nsPop3Protocol::GetPassword(nsCString& aPassword)
{
nsresult rv = NS_OK;
nsCOMPtr<nsIMsgIncomingServer> server = do_QueryInterface(m_pop3Server);
@ -763,7 +763,7 @@ nsresult nsPop3Protocol::GetPassword(nsCString& aPassword, PRBool *okayValue)
// Now go and get the password.
if (!passwordPrompt.IsEmpty() && !passwordTitle.IsEmpty())
rv = server->GetPasswordWithUI(passwordPrompt, passwordTitle,
msgWindow, okayValue, aPassword);
msgWindow, aPassword);
ClearFlag(POP3_PASSWORD_FAILED|POP3_AUTH_FAILURE);
// If it failed, then user pressed the cancel button (or some other
@ -1760,9 +1760,8 @@ PRInt32 nsPop3Protocol::SendUsername()
return(Error(POP3_USERNAME_UNDEFINED));
nsCString password;
PRBool okayValue = PR_TRUE;
nsresult rv = GetPassword(password, &okayValue);
if (NS_SUCCEEDED(rv) && !okayValue)
nsresult rv = GetPassword(password);
if (NS_SUCCEEDED(rv) && rv == NS_MSG_PASSWORD_PROMPT_CANCELLED)
{
// user has canceled the password prompt
m_pop3ConData->next_state = POP3_ERROR_DONE;
@ -1811,9 +1810,8 @@ PRInt32 nsPop3Protocol::SendPassword()
return(Error(POP3_USERNAME_UNDEFINED));
nsCString password;
PRBool okayValue = PR_TRUE;
nsresult rv = GetPassword(password, &okayValue);
if (NS_SUCCEEDED(rv) && !okayValue)
nsresult rv = GetPassword(password);
if (NS_SUCCEEDED(rv) && rv == NS_MSG_PASSWORD_PROMPT_CANCELLED)
{
// user has canceled the password prompt
m_pop3ConData->next_state = POP3_ERROR_DONE;
@ -3443,8 +3441,7 @@ nsresult nsPop3Protocol::ProcessProtocolState(nsIURI * url, nsIInputStream * aIn
prompt the user for a password; just tell him we don't
know whether he has new mail. */
nsCString password;
PRBool okayValue;
GetPassword(password, &okayValue);
GetPassword(password);
const char * pwd = password.get();
if (password.IsEmpty() || m_username.IsEmpty())
{

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

@ -281,7 +281,7 @@ public:
const char* GetUsername() { return m_username.get(); }
void SetUsername(const char* name);
nsresult GetPassword(nsCString& aPassword, PRBool *okayValue);
nsresult GetPassword(nsCString& aPassword);
NS_IMETHOD OnTransportStatus(nsITransport *transport, nsresult status, PRUint64 progress, PRUint64 progressMax);
NS_IMETHOD OnStopRequest(nsIRequest *request, nsISupports * aContext, nsresult aStatus);

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

@ -78,25 +78,21 @@ NS_IMETHODIMP nsRssService::GetDefaultLocalPath(nsILocalFile * *aDefaultLocalPat
NS_IMETHODIMP nsRssService::SetDefaultLocalPath(nsILocalFile * aDefaultLocalPath)
{
NS_ASSERTION(0,"foo");
return NS_ERROR_NOT_IMPLEMENTED;
}
NS_IMETHODIMP nsRssService::GetServerIID(nsIID * *aServerIID)
{
NS_ASSERTION(0,"foo");
return NS_ERROR_NOT_IMPLEMENTED;
}
NS_IMETHODIMP nsRssService::GetRequiresUsername(PRBool *aRequiresUsername)
{
NS_ASSERTION(0,"foo");
return NS_ERROR_NOT_IMPLEMENTED;
}
NS_IMETHODIMP nsRssService::GetPreflightPrettyNameWithEmailAddress(PRBool *aPreflightPrettyNameWithEmailAddress)
{
NS_ASSERTION(0,"foo");
return NS_ERROR_NOT_IMPLEMENTED;
}
@ -158,6 +154,5 @@ NS_IMETHODIMP nsRssService::GetShowComposeMsgLink(PRBool *aShowComposeMsgLink)
NS_IMETHODIMP nsRssService::GetSpecialFoldersDeletionAllowed(PRBool *aSpecialFoldersDeletionAllowed)
{
NS_ASSERTION(0,"foo");
return NS_ERROR_NOT_IMPLEMENTED;
}

Некоторые файлы не были показаны из-за слишком большого количества измененных файлов Показать больше