bug 64983, r=nhotta, sr=sfraser

When open DBCS filename by composer, title is shown incorrectly.
This bug is the regression of sfraser's check in (nsEditorShell.cpp
v1.222).
This commit is contained in:
m_kato%ga2.so-net.ne.jp 2001-01-12 11:29:59 +00:00
Родитель b4347ac7e8
Коммит c9ffdd5eba
2 изменённых файлов: 12 добавлений и 12 удалений

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

@ -1853,10 +1853,10 @@ nsEditorShell::SaveDocument(PRBool saveAs, PRBool saveCopy, PRBool *_retval)
}
else // have a file spec
{
nsXPIDLCString leafName;
docFile->GetLeafName(getter_Copies(leafName));
nsXPIDLString leafName;
docFile->GetUnicodeLeafName(getter_Copies(leafName));
if (leafName.get() && *leafName)
fileName.AssignWithConversion(leafName);
fileName.Assign(leafName);
nsCOMPtr<nsIFile> parentPath;
if (NS_SUCCEEDED(docFile->GetParent(getter_AddRefs(parentPath))))
@ -2120,10 +2120,10 @@ nsEditorShell::UpdateWindowTitle()
nsCOMPtr<nsIFile> docFileSpec;
if (NS_SUCCEEDED(diskDoc->GetFileSpec(getter_AddRefs(docFileSpec))))
{
nsXPIDLCString fileName;
docFileSpec->GetLeafName(getter_Copies(fileName));
nsXPIDLString fileName;
docFileSpec->GetUnicodeLeafName(getter_Copies(fileName));
windowCaption.AppendWithConversion(" [");
windowCaption.AppendWithConversion(fileName);
windowCaption.Append(fileName);
windowCaption.AppendWithConversion("]");
}
}

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

@ -1853,10 +1853,10 @@ nsEditorShell::SaveDocument(PRBool saveAs, PRBool saveCopy, PRBool *_retval)
}
else // have a file spec
{
nsXPIDLCString leafName;
docFile->GetLeafName(getter_Copies(leafName));
nsXPIDLString leafName;
docFile->GetUnicodeLeafName(getter_Copies(leafName));
if (leafName.get() && *leafName)
fileName.AssignWithConversion(leafName);
fileName.Assign(leafName);
nsCOMPtr<nsIFile> parentPath;
if (NS_SUCCEEDED(docFile->GetParent(getter_AddRefs(parentPath))))
@ -2120,10 +2120,10 @@ nsEditorShell::UpdateWindowTitle()
nsCOMPtr<nsIFile> docFileSpec;
if (NS_SUCCEEDED(diskDoc->GetFileSpec(getter_AddRefs(docFileSpec))))
{
nsXPIDLCString fileName;
docFileSpec->GetLeafName(getter_Copies(fileName));
nsXPIDLString fileName;
docFileSpec->GetUnicodeLeafName(getter_Copies(fileName));
windowCaption.AppendWithConversion(" [");
windowCaption.AppendWithConversion(fileName);
windowCaption.Append(fileName);
windowCaption.AppendWithConversion("]");
}
}