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

Unified Diff: chrome/browser/ui/search_engines/edit_search_engine_controller.cc

Issue 7558014: Add a URL param to indicate group selection in Instant field trial. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Passing NULL as far as possible Created 9 years, 4 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: chrome/browser/ui/search_engines/edit_search_engine_controller.cc
diff --git a/chrome/browser/ui/search_engines/edit_search_engine_controller.cc b/chrome/browser/ui/search_engines/edit_search_engine_controller.cc
index a0c9b52bf07fb1de02009b939c8413dc0215ac51..93c1ee14d54fa3343457aec05c327390d6dddc8e 100644
--- a/chrome/browser/ui/search_engines/edit_search_engine_controller.cc
+++ b/chrome/browser/ui/search_engines/edit_search_engine_controller.cc
@@ -53,8 +53,9 @@ bool EditSearchEngineController::IsURLValid(
// If the url has a search term, replace it with a random string and make
// sure the resulting URL is valid. We don't check the validity of the url
// with the search term as that is not necessarily valid.
- return GURL(template_ref.ReplaceSearchTerms(TemplateURL(), ASCIIToUTF16("a"),
- TemplateURLRef::NO_SUGGESTIONS_AVAILABLE, string16())).is_valid();
+ return GURL(template_ref.ReplaceSearchTerms(NULL, TemplateURL(),
+ ASCIIToUTF16("a"), TemplateURLRef::NO_SUGGESTIONS_AVAILABLE, string16()))
+ .is_valid();
}
bool EditSearchEngineController::IsKeywordValid(
@@ -136,8 +137,8 @@ std::string EditSearchEngineController::GetFixedUpURL(
// we need to replace the search terms before testing for the scheme.
TemplateURL t_url;
t_url.SetURL(url, 0, 0);
- std::string expanded_url =
- t_url.url()->ReplaceSearchTerms(t_url, ASCIIToUTF16("x"), 0, string16());
+ std::string expanded_url = t_url.url()->ReplaceSearchTerms(NULL, t_url,
+ ASCIIToUTF16("x"), 0, string16());
url_parse::Parsed parts;
std::string scheme(
URLFixerUpper::SegmentURL(expanded_url, &parts));
@@ -148,4 +149,3 @@ std::string EditSearchEngineController::GetFixedUpURL(
return url;
}
-
« chrome/browser/search_engines/template_url.h ('K') | « chrome/browser/ui/browser_init.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698