Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(230)

Unified Diff: components/omnibox/browser/search_provider.cc

Issue 1983773002: Cache SearchEngineType of TemplateURL (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@refactor-extracting-terms-from-template-url
Patch Set: Fix typo Created 4 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: components/omnibox/browser/search_provider.cc
diff --git a/components/omnibox/browser/search_provider.cc b/components/omnibox/browser/search_provider.cc
index 5d6ae6b771148c13099a4f2f6ba4824615333495..2f2691ceeecb5861f847e2f5378c81b3b98d2b1a 100644
--- a/components/omnibox/browser/search_provider.cc
+++ b/components/omnibox/browser/search_provider.cc
@@ -33,7 +33,6 @@
#include "components/omnibox/browser/suggestion_answer.h"
#include "components/omnibox/browser/url_prefix.h"
#include "components/search/search.h"
-#include "components/search_engines/template_url_prepopulate_data.h"
#include "components/search_engines/template_url_service.h"
#include "components/url_formatter/url_formatter.h"
#include "components/variations/net/variations_http_headers.h"
@@ -488,9 +487,8 @@ void SearchProvider::LogFetchComplete(bool success, bool is_keyword) {
// non-keyword mode.
const TemplateURL* default_url = providers_.GetDefaultProviderURL();
if (!is_keyword && default_url &&
- (TemplateURLPrepopulateData::GetEngineType(
- *default_url,
- client()->GetTemplateURLService()->search_terms_data()) ==
+ (default_url->GetEngineType(
+ client()->GetTemplateURLService()->search_terms_data()) ==
SEARCH_ENGINE_GOOGLE)) {
const base::TimeDelta elapsed_time =
base::TimeTicks::Now() - time_suggest_request_sent_;

Powered by Google App Engine
This is Rietveld 408576698