still more nsString->nsAutoString cleanup

This commit is contained in:
alecf%netscape.com 2000-01-05 03:06:03 +00:00
Родитель 6105a4546e
Коммит 8225da9a99
6 изменённых файлов: 9 добавлений и 9 удалений

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

@ -344,7 +344,7 @@ nsMsgAccount::SetKey(const char *accountKey)
NS_IMETHODIMP
nsMsgAccount::ToString(PRUnichar **aResult)
{
nsString val("[nsIMsgAccount: ");
nsAutoString val("[nsIMsgAccount: ");
val += m_accountKey;
val += "]";
*aResult = val.ToNewUnicode();

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

@ -1720,7 +1720,7 @@ nsMsgAccountManager::CreateLocalMailAccount(nsIMsgIdentity *identity)
// we don't want "nobody at Local Mail" to show up in the
// folder pane, so we set the pretty name to "Local Mail"
nsString localMailFakeHostName(LOCAL_MAIL_FAKE_HOST_NAME);
nsAutoString localMailFakeHostName(LOCAL_MAIL_FAKE_HOST_NAME);
server->SetPrettyName(localMailFakeHostName.ToNewUnicode());
// the server needs a username
@ -1864,7 +1864,7 @@ nsMsgAccountManager::MigrateLocalMailAccount(nsIMsgIdentity *identity)
// we don't want "nobody at Local Mail" to show up in the
// folder pane, so we set the pretty name to "Local Mail"
nsString localMailFakeHostName(LOCAL_MAIL_FAKE_HOST_NAME);
nsAutoString localMailFakeHostName(LOCAL_MAIL_FAKE_HOST_NAME);
server->SetPrettyName(localMailFakeHostName.ToNewUnicode());
// create the directory structure for old 4.x "Local Mail"

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

@ -191,7 +191,7 @@ nsMsgAccountManagerDataSource::GetTarget(nsIRDFResource *source,
rv = NS_RDF_NO_VALUE;
nsString str="";
nsAutoString str("");
if (property == kNC_Name || property == kNC_FolderTreeName) {
// XXX these should be localized

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

@ -1429,7 +1429,7 @@ nsresult nsMsgFolderDataSource::DoNewFolder(nsIMsgFolder *folder, nsISupportsArr
{
PRUnichar *name;
literal->GetValue(&name);
nsString tempStr = name;
nsAutoString tempStr(name);
nsAutoCString nameStr(tempStr);
rv = folder->CreateSubfolder(nameStr);

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

@ -179,7 +179,7 @@ nsresult nsMsgMessageDataSource::Init()
nsresult nsMsgMessageDataSource::CreateLiterals(nsIRDFService *rdf)
{
nsString str = " ";
nsAutoString str(" ");;
createNode(str, getter_AddRefs(kEmptyStringLiteral), rdf);
str = "lowest";
createNode(str, getter_AddRefs(kLowestLiteral), rdf);
@ -1076,7 +1076,7 @@ nsMsgMessageDataSource::createMessageSizeNode(nsIMessage *message,
{
nsresult rv;
PRUint32 size;
nsString sizeStr="";
nsAutoString sizeStr("");
rv = message->GetMessageSize(&size);
if(NS_FAILED(rv))
return rv;
@ -1099,7 +1099,7 @@ nsresult nsMsgMessageDataSource::createMessageTotalNode(nsIMessage *message, nsI
nsCOMPtr<nsIMsgFolder> folder;
nsCOMPtr<nsIMsgThread> thread;
nsresult rv;
nsString emptyString("");
nsAutoString emptyString("");
PRBool showThreads;
GetIsThreaded(&showThreads);

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

@ -351,7 +351,7 @@ nsresult nsMsgRDFDataSource::NotifyPropertyChanged(nsIRDFResource *resource,
const char *newValue)
{
nsCOMPtr<nsIRDFNode> newValueNode;
nsString newValueStr = newValue;
nsAutoString newValueStr(newValue);
createNode(newValueStr, getter_AddRefs(newValueNode), getRDFService());
NotifyPropertyChanged(resource, propertyResource, newValueNode);
return NS_OK;