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

Unified Diff: chrome/browser/ui/webui/options/geolocation_options_handler.cc

Issue 21985002: Add Finch Checks to the State Machine (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@SMLog
Patch Set: Quick Fixes Created 7 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/webui/options/geolocation_options_handler.cc
diff --git a/chrome/browser/ui/webui/options/geolocation_options_handler.cc b/chrome/browser/ui/webui/options/geolocation_options_handler.cc
index 47ec77c4cf4ff6d47969e543943df68ae3a716d2..2e64185c55f968a7cf44b131ff9751119c601eef 100644
--- a/chrome/browser/ui/webui/options/geolocation_options_handler.cc
+++ b/chrome/browser/ui/webui/options/geolocation_options_handler.cc
@@ -22,7 +22,13 @@ void GeolocationOptionsHandler::GetLocalizedValues(
void GeolocationOptionsHandler::InitializePage() {
DCHECK(web_ui());
- if ((base::FieldTrialList::FindFullName("GoogleNow") == "Enable") ||
+ std::string enable_prefix("Enable");
+ std::string field_trial_result =
+ base::FieldTrialList::FindFullName("GoogleNow");
+ if ((field_trial_result.compare(
+ 0,
+ enable_prefix.length(),
+ enable_prefix) == 0) ||
CommandLine::ForCurrentProcess()->HasSwitch(
switches::kEnableGoogleNowIntegration)) {
web_ui()->CallJavascriptFunction(

Powered by Google App Engine
This is Rietveld 408576698