From e7a5b787751ed3c1c31f66ae919f11911393b974 Mon Sep 17 00:00:00 2001 From: "pkasting@chromium.org" Date: Wed, 10 Dec 2008 23:52:43 +0000 Subject: Make the autocomplete system and various other connected bits of code use GURL instead of wstring where appropriate. Original patch by phajdan.jr@gmail.com, r=me,sky. See http://codereview.chromium.org/13205 . BUG=715234 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@6758 0039d316-1c4b-4281-b951-d872f2087c98 --- chrome/browser/net/dns_global.cc | 10 ++++------ chrome/browser/net/dns_global.h | 2 +- 2 files changed, 5 insertions(+), 7 deletions(-) (limited to 'chrome/browser/net') diff --git a/chrome/browser/net/dns_global.cc b/chrome/browser/net/dns_global.cc index 727af82..eb8d79f 100644 --- a/chrome/browser/net/dns_global.cc +++ b/chrome/browser/net/dns_global.cc @@ -88,14 +88,12 @@ static void DnsPrefetchMotivatedList( dns_master->ResolveList(hostnames, motivation); } -// This API is used by the autocomplete popup box (wher URLs are typed). -void DnsPrefetchUrlString(const url_canon::UTF16String& url_string) { +// This API is used by the autocomplete popup box (where URLs are typed). +void DnsPrefetchUrl(const GURL& url) { if (!dns_prefetch_enabled || NULL == dns_master) return; - GURL gurl(url_string); - if (gurl.is_valid()) { - DnsMotivatedPrefetch(gurl.host(), DnsHostInfo::OMNIBOX_MOTIVATED); - } + if (url.is_valid()) + DnsMotivatedPrefetch(url.host(), DnsHostInfo::OMNIBOX_MOTIVATED); } static void DnsMotivatedPrefetch(const std::string& hostname, diff --git a/chrome/browser/net/dns_global.h b/chrome/browser/net/dns_global.h index 3b76f45..7bf441d 100644 --- a/chrome/browser/net/dns_global.h +++ b/chrome/browser/net/dns_global.h @@ -31,7 +31,7 @@ void RegisterUserPrefs(PrefService* user_prefs); // Renderer bundles up list and sends to this browser API via IPC. void DnsPrefetchList(const NameList& hostnames); // This API is used by the autocomplete popup box (as user types). -void DnsPrefetchUrlString(const url_canon::UTF16String& url_string); +void DnsPrefetchUrl(const GURL& url); void DnsPrefetchGetHtmlInfo(std::string* output); //------------------------------------------------------------------------------ -- cgit v1.1