зеркало из https://github.com/mozilla/pjs.git
r=sspitzer, a=brendan OS/2 bringup - VisualAge treats this like a cast - according to nsFileSpec.h, our way is correct
This commit is contained in:
Родитель
83b8bd6fea
Коммит
ec38ff3ddb
|
@ -318,7 +318,7 @@ int nsAccount::IterateDirectoryChildren(nsFileSpec& startChild)
|
||||||
{
|
{
|
||||||
printf ("Inside the iteration \n");
|
printf ("Inside the iteration \n");
|
||||||
|
|
||||||
char* itemName = ((nsFileSpec&)i).GetLeafName();
|
char* itemName = (i.Spec()).GetLeafName();
|
||||||
PL_strcpy(gNCIInfo[NCICount], itemName);
|
PL_strcpy(gNCIInfo[NCICount], itemName);
|
||||||
mConsole << '\t' << itemName << nsEndl;
|
mConsole << '\t' << itemName << nsEndl;
|
||||||
mConsole << '\t' << "This is the arraynumber "<<NCICount<<"and value" <<gNCIInfo[NCICount] << nsEndl;
|
mConsole << '\t' << "This is the arraynumber "<<NCICount<<"and value" <<gNCIInfo[NCICount] << nsEndl;
|
||||||
|
|
|
@ -1283,7 +1283,7 @@ nsPrefMigration::GetSizes(nsFileSpec inputPath, PRBool readSubdirs, PRUint32 *si
|
||||||
|
|
||||||
for (nsDirectoryIterator dir(inputPath, PR_FALSE); dir.Exists(); dir++)
|
for (nsDirectoryIterator dir(inputPath, PR_FALSE); dir.Exists(); dir++)
|
||||||
{
|
{
|
||||||
nsFileSpec fileOrDirName = (nsFileSpec&)dir;
|
nsFileSpec fileOrDirName = dir.Spec();
|
||||||
folderName = fileOrDirName.GetLeafName();
|
folderName = fileOrDirName.GetLeafName();
|
||||||
fileOrDirNameStr.AssignWithConversion(folderName);
|
fileOrDirNameStr.AssignWithConversion(folderName);
|
||||||
if (nsStringEndsWith(fileOrDirNameStr, MAIL_SUMMARY_SUFFIX_IN_4x) || nsStringEndsWith(fileOrDirNameStr, NEWS_SUMMARY_SUFFIX_IN_4x) || nsStringEndsWith(fileOrDirNameStr, SUMMARY_SUFFIX_IN_5x)) /* Don't copy the summary files */
|
if (nsStringEndsWith(fileOrDirNameStr, MAIL_SUMMARY_SUFFIX_IN_4x) || nsStringEndsWith(fileOrDirNameStr, NEWS_SUMMARY_SUFFIX_IN_4x) || nsStringEndsWith(fileOrDirNameStr, SUMMARY_SUFFIX_IN_5x)) /* Don't copy the summary files */
|
||||||
|
@ -1416,7 +1416,7 @@ nsPrefMigration::CopyAndRenameNewsrcFiles(nsIFileSpec * newPathSpec)
|
||||||
|
|
||||||
for (nsDirectoryIterator dir(oldPath, PR_FALSE); dir.Exists(); dir++)
|
for (nsDirectoryIterator dir(oldPath, PR_FALSE); dir.Exists(); dir++)
|
||||||
{
|
{
|
||||||
nsFileSpec fileOrDirName = (nsFileSpec&)dir; //set first file or dir to a nsFileSpec
|
nsFileSpec fileOrDirName = dir.Spec(); //set first file or dir to a nsFileSpec
|
||||||
folderName = fileOrDirName.GetLeafName(); //get the filename without the full path
|
folderName = fileOrDirName.GetLeafName(); //get the filename without the full path
|
||||||
fileOrDirNameStr.AssignWithConversion(folderName);
|
fileOrDirNameStr.AssignWithConversion(folderName);
|
||||||
|
|
||||||
|
@ -1474,7 +1474,7 @@ nsPrefMigration::DoTheCopyAndRename(nsIFileSpec * oldPathSpec, nsIFileSpec *newP
|
||||||
|
|
||||||
for (nsDirectoryIterator dir(oldPath, PR_FALSE); dir.Exists(); dir++)
|
for (nsDirectoryIterator dir(oldPath, PR_FALSE); dir.Exists(); dir++)
|
||||||
{
|
{
|
||||||
nsFileSpec fileOrDirName = (nsFileSpec&)dir; //set first file or dir to a nsFileSpec
|
nsFileSpec fileOrDirName = dir.Spec(); //set first file or dir to a nsFileSpec
|
||||||
folderName = fileOrDirName.GetLeafName(); //get the filename without the full path
|
folderName = fileOrDirName.GetLeafName(); //get the filename without the full path
|
||||||
fileOrDirNameStr.AssignWithConversion(folderName);
|
fileOrDirNameStr.AssignWithConversion(folderName);
|
||||||
|
|
||||||
|
|
Загрузка…
Ссылка в новой задаче