mirror of
https://github.com/mozilla/gecko-dev.git
synced 2025-01-09 05:14:24 +00:00
Bug 738209 - Cleanup a usages of NS_Convert*to*() in places. r=mak
This commit is contained in:
parent
2bbc3d0175
commit
7ac19d776f
@ -72,7 +72,7 @@ nsAndroidHistory::RegisterVisitedCallback(nsIURI *aURI, Link *aContent)
|
||||
nsCAutoString uri;
|
||||
nsresult rv = aURI->GetSpec(uri);
|
||||
if (NS_FAILED(rv)) return rv;
|
||||
nsString uriString = NS_ConvertUTF8toUTF16(uri);
|
||||
NS_ConvertUTF8toUTF16 uriString(uri);
|
||||
|
||||
nsTArray<Link*>* list = mListeners.Get(uriString);
|
||||
if (! list) {
|
||||
@ -98,7 +98,7 @@ nsAndroidHistory::UnregisterVisitedCallback(nsIURI *aURI, Link *aContent)
|
||||
nsCAutoString uri;
|
||||
nsresult rv = aURI->GetSpec(uri);
|
||||
if (NS_FAILED(rv)) return rv;
|
||||
nsString uriString = NS_ConvertUTF8toUTF16(uri);
|
||||
NS_ConvertUTF8toUTF16 uriString(uri);
|
||||
|
||||
nsTArray<Link*>* list = mListeners.Get(uriString);
|
||||
if (! list)
|
||||
@ -126,7 +126,7 @@ nsAndroidHistory::VisitURI(nsIURI *aURI, nsIURI *aLastVisitedURI, PRUint32 aFlag
|
||||
nsCAutoString uri;
|
||||
nsresult rv = aURI->GetSpec(uri);
|
||||
if (NS_FAILED(rv)) return rv;
|
||||
nsString uriString = NS_ConvertUTF8toUTF16(uri);
|
||||
NS_ConvertUTF8toUTF16 uriString(uri);
|
||||
bridge->MarkURIVisited(uriString);
|
||||
}
|
||||
return NS_OK;
|
||||
|
@ -791,7 +791,7 @@ nsNavHistory::TokensToQueries(const nsTArray<QueryKeyValuePair>& aTokens,
|
||||
} else if (kvp.key.EqualsLiteral(QUERYKEY_TAG)) {
|
||||
nsCAutoString unescaped(kvp.value);
|
||||
NS_UnescapeURL(unescaped); // modifies input
|
||||
nsString tag = NS_ConvertUTF8toUTF16(unescaped);
|
||||
NS_ConvertUTF8toUTF16 tag(unescaped);
|
||||
if (!tags.Contains(tag)) {
|
||||
NS_ENSURE_TRUE(tags.AppendElement(tag), NS_ERROR_OUT_OF_MEMORY);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user