Index: ash/wm/session_lock_state_controller.cc |
diff --git a/ash/wm/session_lock_state_controller.cc b/ash/wm/session_lock_state_controller.cc |
new file mode 100644 |
index 0000000000000000000000000000000000000000..b18c86bf83ce8e90e35addb5b7900c092d7d6317 |
--- /dev/null |
+++ b/ash/wm/session_lock_state_controller.cc |
@@ -0,0 +1,56 @@ |
+// Copyright (c) 2012 The Chromium Authors. All rights reserved. |
+// Use of this source code is governed by a BSD-style license that can be |
+// found in the LICENSE file. |
+ |
+#include "ash/wm/session_lock_state_controller.h" |
+ |
+#include "ash/ash_switches.h" |
+#include "ash/shell.h" |
+#include "ash/shell_delegate.h" |
+#include "ash/shell_window_ids.h" |
+#include "ash/wm/session_state_animator.h" |
+#include "base/command_line.h" |
+#include "ui/aura/root_window.h" |
+#include "ui/views/corewm/compound_event_filter.h" |
+ |
+#if defined(OS_CHROMEOS) |
+#include "base/chromeos/chromeos_version.h" |
+#endif |
+ |
+namespace ash { |
+ |
+const int SessionLockStateController::kLockTimeoutMs = 400; |
+const int SessionLockStateController::kShutdownTimeoutMs = 400; |
+const int SessionLockStateController::kLockFailTimeoutMs = 4000; |
+const int SessionLockStateController::kLockToShutdownTimeoutMs = 150; |
+const int SessionLockStateController::kShutdownRequestDelayMs = 50; |
+ |
+SessionLockStateController::SessionLockStateController() |
+ : animator_(new internal::SessionStateAnimator()) { |
+} |
+ |
+SessionLockStateController::~SessionLockStateController() { |
+} |
+ |
+void SessionLockStateController::SetDelegate( |
+ SessionLockStateControllerDelegate* delegate) { |
+ delegate_.reset(delegate); |
+} |
+ |
+void SessionLockStateController::AddObserver( |
+ SessionLockStateObserver* observer) { |
+ observers_.AddObserver(observer); |
+} |
+ |
+void SessionLockStateController::RemoveObserver( |
+ SessionLockStateObserver* observer) { |
+ observers_.RemoveObserver(observer); |
+} |
+ |
+bool SessionLockStateController::HasObserver( |
+ SessionLockStateObserver* observer) { |
+ return observers_.HasObserver(observer); |
+} |
+ |
+ |
+} // namespace ash |