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

Unified Diff: chrome/browser/signin/easy_unlock_service.cc

Issue 785663003: easy-unlock: Turn on by default. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: fix tests Created 6 years 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
« no previous file with comments | « no previous file | chrome/browser/signin/easy_unlock_service_browsertest_chromeos.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/signin/easy_unlock_service.cc
diff --git a/chrome/browser/signin/easy_unlock_service.cc b/chrome/browser/signin/easy_unlock_service.cc
index 2c90f81781a0094b4290c4402223538d4f5fdd1a..2219283607912f325b534920a4a4a9ef12bd25a8 100644
--- a/chrome/browser/signin/easy_unlock_service.cc
+++ b/chrome/browser/signin/easy_unlock_service.cc
@@ -7,7 +7,6 @@
#include "base/bind.h"
#include "base/command_line.h"
#include "base/logging.h"
-#include "base/metrics/field_trial.h"
#include "base/prefs/pref_registry_simple.h"
#include "base/prefs/pref_service.h"
#include "base/prefs/scoped_user_pref_update.h"
@@ -81,21 +80,8 @@ EasyUnlockService* EasyUnlockService::GetForUser(
// static
bool EasyUnlockService::IsSignInEnabled() {
- // Note: It's important to query the field trial state first, to ensure that
- // UMA reports the correct group.
- const std::string group = base::FieldTrialList::FindFullName("EasySignIn");
-
- if (CommandLine::ForCurrentProcess()->HasSwitch(
- proximity_auth::switches::kDisableEasySignin)) {
- return false;
- }
-
- if (CommandLine::ForCurrentProcess()->HasSwitch(
- proximity_auth::switches::kEnableEasySignin)) {
- return true;
- }
-
- return group == "Enable";
+ return !CommandLine::ForCurrentProcess()->HasSwitch(
+ proximity_auth::switches::kDisableEasySignin);
}
class EasyUnlockService::BluetoothDetector
@@ -248,6 +234,11 @@ bool EasyUnlockService::IsAllowed() {
if (shut_down_)
return false;
+ if (CommandLine::ForCurrentProcess()->HasSwitch(
+ proximity_auth::switches::kDisableEasyUnlock)) {
+ return false;
+ }
+
if (!IsAllowedInternal())
return false;
« no previous file with comments | « no previous file | chrome/browser/signin/easy_unlock_service_browsertest_chromeos.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698