fake_screen_lock_manager.cc 766 B

12345678910111213141516171819202122232425262728
  1. // Copyright 2021 The Chromium Authors. All rights reserved.
  2. // Use of this source code is governed by a BSD-style license that can be
  3. // found in the LICENSE file.
  4. #include "ash/components/phonehub/fake_screen_lock_manager.h"
  5. namespace ash {
  6. namespace phonehub {
  7. FakeScreenLockManager::FakeScreenLockManager(LockStatus lock_status)
  8. : lock_status_(lock_status) {}
  9. FakeScreenLockManager::~FakeScreenLockManager() = default;
  10. ScreenLockManager::LockStatus FakeScreenLockManager::GetLockStatus() const {
  11. return lock_status_;
  12. }
  13. void FakeScreenLockManager::SetLockStatusInternal(LockStatus lock_status) {
  14. if (lock_status_ == lock_status)
  15. return;
  16. lock_status_ = lock_status;
  17. NotifyScreenLockChanged();
  18. }
  19. } // namespace phonehub
  20. } // namespace ash