OLD | NEW |
(Empty) | |
| 1 // Copyright (c) 2013 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 |
| 5 #include "ash/session_state_delegate_stub.h" |
| 6 |
| 7 #include "ash/shell.h" |
| 8 #include "ash/shell/example_factory.h" |
| 9 |
| 10 namespace ash { |
| 11 |
| 12 SessionStateDelegateStub::SessionStateDelegateStub() : screen_locked_(false) { |
| 13 } |
| 14 |
| 15 SessionStateDelegateStub::~SessionStateDelegateStub() { |
| 16 } |
| 17 |
| 18 bool SessionStateDelegateStub::HasActiveUser() const { |
| 19 return true; |
| 20 } |
| 21 |
| 22 bool SessionStateDelegateStub::IsActiveUserSessionStarted() const { |
| 23 return true; |
| 24 } |
| 25 |
| 26 bool SessionStateDelegateStub::CanLockScreen() const { |
| 27 return true; |
| 28 } |
| 29 |
| 30 bool SessionStateDelegateStub::IsScreenLocked() const { |
| 31 return screen_locked_; |
| 32 } |
| 33 |
| 34 void SessionStateDelegateStub::LockScreen() { |
| 35 shell::CreateLockScreen(); |
| 36 screen_locked_ = true; |
| 37 Shell::GetInstance()->UpdateShelfVisibility(); |
| 38 } |
| 39 |
| 40 void SessionStateDelegateStub::UnlockScreen() { |
| 41 screen_locked_ = false; |
| 42 Shell::GetInstance()->UpdateShelfVisibility(); |
| 43 } |
| 44 |
| 45 } // namespace ash |
OLD | NEW |