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

Side by Side Diff: chrome/browser/signin/easy_unlock_service.cc

Issue 485243002: Fix few minor easy unlock bugs (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: . Created 6 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "chrome/browser/signin/easy_unlock_service.h" 5 #include "chrome/browser/signin/easy_unlock_service.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/command_line.h" 8 #include "base/command_line.h"
9 #include "base/logging.h" 9 #include "base/logging.h"
10 #include "base/memory/ref_counted.h" 10 #include "base/memory/ref_counted.h"
(...skipping 113 matching lines...) Expand 10 before | Expand all | Expand 10 after
124 124
125 // static 125 // static
126 void EasyUnlockService::RegisterProfilePrefs( 126 void EasyUnlockService::RegisterProfilePrefs(
127 user_prefs::PrefRegistrySyncable* registry) { 127 user_prefs::PrefRegistrySyncable* registry) {
128 registry->RegisterBooleanPref( 128 registry->RegisterBooleanPref(
129 prefs::kEasyUnlockEnabled, 129 prefs::kEasyUnlockEnabled,
130 false, 130 false,
131 user_prefs::PrefRegistrySyncable::UNSYNCABLE_PREF); 131 user_prefs::PrefRegistrySyncable::UNSYNCABLE_PREF);
132 registry->RegisterBooleanPref( 132 registry->RegisterBooleanPref(
133 prefs::kEasyUnlockShowTutorial, 133 prefs::kEasyUnlockShowTutorial,
134 false, 134 true,
135 user_prefs::PrefRegistrySyncable::UNSYNCABLE_PREF); 135 user_prefs::PrefRegistrySyncable::UNSYNCABLE_PREF);
136 registry->RegisterDictionaryPref( 136 registry->RegisterDictionaryPref(
137 prefs::kEasyUnlockPairing, 137 prefs::kEasyUnlockPairing,
138 new base::DictionaryValue(), 138 new base::DictionaryValue(),
139 user_prefs::PrefRegistrySyncable::UNSYNCABLE_PREF); 139 user_prefs::PrefRegistrySyncable::UNSYNCABLE_PREF);
140 registry->RegisterBooleanPref( 140 registry->RegisterBooleanPref(
141 prefs::kEasyUnlockAllowed, 141 prefs::kEasyUnlockAllowed,
142 true, 142 true,
143 user_prefs::PrefRegistrySyncable::UNSYNCABLE_PREF); 143 user_prefs::PrefRegistrySyncable::UNSYNCABLE_PREF);
144 } 144 }
(...skipping 209 matching lines...) Expand 10 before | Expand all | Expand 10 after
354 turn_off_flow_.reset(); 354 turn_off_flow_.reset();
355 355
356 if (!success) { 356 if (!success) {
357 SetTurnOffFlowStatus(FAIL); 357 SetTurnOffFlowStatus(FAIL);
358 return; 358 return;
359 } 359 }
360 360
361 ClearRemoteDevices(); 361 ClearRemoteDevices();
362 SetTurnOffFlowStatus(IDLE); 362 SetTurnOffFlowStatus(IDLE);
363 363
364 // Make sure lock screen state set by the extension gets reset.
365 screenlock_state_handler_.reset();
366
364 if (GetComponentLoader(profile_)->Exists(extension_misc::kEasyUnlockAppId)) { 367 if (GetComponentLoader(profile_)->Exists(extension_misc::kEasyUnlockAppId)) {
365 extensions::ExtensionSystem* extension_system = 368 extensions::ExtensionSystem* extension_system =
366 extensions::ExtensionSystem::Get(profile_); 369 extensions::ExtensionSystem::Get(profile_);
367 extension_system->extension_service()->ReloadExtension( 370 extension_system->extension_service()->ReloadExtension(
368 extension_misc::kEasyUnlockAppId); 371 extension_misc::kEasyUnlockAppId);
369 } 372 }
370 } 373 }
OLDNEW
« no previous file with comments | « chrome/browser/signin/easy_unlock_screenlock_state_handler.cc ('k') | chrome/common/extensions/api/easy_unlock_private.idl » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698