зеркало из https://github.com/mozilla/pjs.git
still more nsString->nsAutoString cleanup
This commit is contained in:
Родитель
848260da51
Коммит
f5f752106a
|
@ -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;
|
||||
|
|
Загрузка…
Ссылка в новой задаче