| OLD | NEW |
| 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/metrics/histogram_macros.h" | 10 #include "base/metrics/histogram_macros.h" |
| (...skipping 504 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 515 observers_.RemoveObserver(observer); | 515 observers_.RemoveObserver(observer); |
| 516 } | 516 } |
| 517 | 517 |
| 518 void EasyUnlockService::Shutdown() { | 518 void EasyUnlockService::Shutdown() { |
| 519 if (shut_down_) | 519 if (shut_down_) |
| 520 return; | 520 return; |
| 521 shut_down_ = true; | 521 shut_down_ = true; |
| 522 | 522 |
| 523 ShutdownInternal(); | 523 ShutdownInternal(); |
| 524 | 524 |
| 525 app_manager_->DisableAppIfLoaded(); | |
| 526 | |
| 527 ResetScreenlockState(); | 525 ResetScreenlockState(); |
| 528 bluetooth_detector_.reset(); | 526 bluetooth_detector_.reset(); |
| 529 #if defined(OS_CHROMEOS) | 527 #if defined(OS_CHROMEOS) |
| 530 power_monitor_.reset(); | 528 power_monitor_.reset(); |
| 531 #endif | 529 #endif |
| 532 | 530 |
| 533 weak_ptr_factory_.InvalidateWeakPtrs(); | 531 weak_ptr_factory_.InvalidateWeakPtrs(); |
| 534 } | 532 } |
| 535 | 533 |
| 536 void EasyUnlockService::ReloadAppAndLockScreen() { | 534 void EasyUnlockService::ReloadAppAndLockScreen() { |
| (...skipping 209 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 746 | 744 |
| 747 // TODO(tbarzic): Set check_private_key only if previous sign-in attempt | 745 // TODO(tbarzic): Set check_private_key only if previous sign-in attempt |
| 748 // failed. | 746 // failed. |
| 749 EasyUnlockTpmKeyManagerFactory::GetInstance()->Get(profile_) | 747 EasyUnlockTpmKeyManagerFactory::GetInstance()->Get(profile_) |
| 750 ->PrepareTpmKey(true /* check_private_key */, | 748 ->PrepareTpmKey(true /* check_private_key */, |
| 751 base::Closure()); | 749 base::Closure()); |
| 752 #endif // defined(OS_CHROMEOS) | 750 #endif // defined(OS_CHROMEOS) |
| 753 | 751 |
| 754 tpm_key_checked_ = true; | 752 tpm_key_checked_ = true; |
| 755 } | 753 } |
| OLD | NEW |