mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-10-09 11:25:00 +00:00
Bug 724841 - Retain case when sending location bar text to search engine service r=bz
This commit is contained in:
parent
2959b5c867
commit
2974faa0ea
@ -3896,6 +3896,10 @@ nsDocShell::LoadURI(const PRUnichar * aURI,
|
|||||||
|
|
||||||
rv = LoadURI(uri, loadInfo, extraFlags, true);
|
rv = LoadURI(uri, loadInfo, extraFlags, true);
|
||||||
|
|
||||||
|
// Save URI string in case it's needed later when
|
||||||
|
// sending to search engine service in EndPageLoad()
|
||||||
|
mOriginalUriString = uriString;
|
||||||
|
|
||||||
return rv;
|
return rv;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -6355,6 +6359,11 @@ nsDocShell::EndPageLoad(nsIWebProgress * aProgress,
|
|||||||
|
|
||||||
if (keywordsEnabled && (kNotFound == dotLoc)) {
|
if (keywordsEnabled && (kNotFound == dotLoc)) {
|
||||||
// only send non-qualified hosts to the keyword server
|
// only send non-qualified hosts to the keyword server
|
||||||
|
if (!mOriginalUriString.IsEmpty()) {
|
||||||
|
sURIFixup->KeywordToURI(mOriginalUriString,
|
||||||
|
getter_AddRefs(newURI));
|
||||||
|
}
|
||||||
|
else {
|
||||||
//
|
//
|
||||||
// If this string was passed through nsStandardURL by
|
// If this string was passed through nsStandardURL by
|
||||||
// chance, then it may have been converted from UTF-8 to
|
// chance, then it may have been converted from UTF-8 to
|
||||||
@ -6376,6 +6385,7 @@ nsDocShell::EndPageLoad(nsIWebProgress * aProgress,
|
|||||||
getter_AddRefs(newURI));
|
getter_AddRefs(newURI));
|
||||||
else
|
else
|
||||||
sURIFixup->KeywordToURI(host, getter_AddRefs(newURI));
|
sURIFixup->KeywordToURI(host, getter_AddRefs(newURI));
|
||||||
|
}
|
||||||
} // end keywordsEnabled
|
} // end keywordsEnabled
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -8070,6 +8080,7 @@ nsDocShell::InternalLoad(nsIURI * aURI,
|
|||||||
nsIRequest** aRequest)
|
nsIRequest** aRequest)
|
||||||
{
|
{
|
||||||
nsresult rv = NS_OK;
|
nsresult rv = NS_OK;
|
||||||
|
mOriginalUriString.Truncate();
|
||||||
|
|
||||||
#ifdef PR_LOGGING
|
#ifdef PR_LOGGING
|
||||||
if (gDocShellLeakLog && PR_LOG_TEST(gDocShellLeakLog, PR_LOG_DEBUG)) {
|
if (gDocShellLeakLog && PR_LOG_TEST(gDocShellLeakLog, PR_LOG_DEBUG)) {
|
||||||
|
@ -849,6 +849,7 @@ private:
|
|||||||
nsCOMPtr<nsIAtom> mParentCharset;
|
nsCOMPtr<nsIAtom> mParentCharset;
|
||||||
nsTObserverArray<nsWeakPtr> mPrivacyObservers;
|
nsTObserverArray<nsWeakPtr> mPrivacyObservers;
|
||||||
PRInt32 mParentCharsetSource;
|
PRInt32 mParentCharsetSource;
|
||||||
|
nsCString mOriginalUriString;
|
||||||
|
|
||||||
#ifdef DEBUG
|
#ifdef DEBUG
|
||||||
// We're counting the number of |nsDocShells| to help find leaks
|
// We're counting the number of |nsDocShells| to help find leaks
|
||||||
|
Loading…
Reference in New Issue
Block a user