зеркало из https://github.com/mozilla/gecko-dev.git
fix for #36488. thanks to andrew.taylor@cal.montage.ca for the initial patch.
make it so in the drafts and unsent message folders we change the sender column to the recipient column. r=sspitzer, sr=bienvenu
This commit is contained in:
Родитель
176bf62c00
Коммит
25988e7f9d
|
@ -278,7 +278,7 @@ function RerootFolder(uri, newFolder, isThreaded, sortID, sortDirection)
|
|||
else
|
||||
SortThreadPane("DateColumn", "http://home.netscape.com/NC-rdf#Date", "", false, null, false);
|
||||
|
||||
SetSentFolderColumns(IsSpecialFolder(newFolder, "Sent"));
|
||||
SetSentFolderColumns(IsSpecialFolder(newFolder, [ "Sent", "Drafts", "Unsent Messages" ]));
|
||||
|
||||
// Since SetSentFolderColumns() may alter the template's structure,
|
||||
// we need to explicitly force the builder to recompile its rules.
|
||||
|
@ -825,7 +825,7 @@ function OpenToFolder(item, folderURI)
|
|||
}
|
||||
|
||||
|
||||
function IsSpecialFolder(msgFolder, specialFolderName)
|
||||
function IsSpecialFolder(msgFolder, specialFolderNames)
|
||||
{
|
||||
var db = GetFolderDatasource();
|
||||
var folderResource = msgFolder.QueryInterface(Components.interfaces.nsIRDFResource);
|
||||
|
@ -838,10 +838,16 @@ function IsSpecialFolder(msgFolder, specialFolderName)
|
|||
if (!result) return false;
|
||||
result = result.QueryInterface(Components.interfaces.nsIRDFLiteral);
|
||||
if (!result) return false;
|
||||
dump("We are looking for " + specialFolderName + "\n");
|
||||
dump("special folder name = " + result.Value + "\n");
|
||||
if(result.Value == specialFolderName)
|
||||
return true;
|
||||
|
||||
//dump("We are looking for " + specialFolderNames + "\n");
|
||||
//dump("special folder name = " + result.Value + "\n");
|
||||
|
||||
var count = specialFolderNames.length;
|
||||
var i;
|
||||
for (i = 0; i < count; i++) {
|
||||
if(result.Value == specialFolderNames[i])
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
||||
return false;
|
||||
|
|
Загрузка…
Ссылка в новой задаче