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 #ifndef CHROME_BROWSER_CHROMEOS_IDLE_DETECTOR_H_ | 5 #ifndef CHROME_BROWSER_CHROMEOS_IDLE_DETECTOR_H_ |
6 #define CHROME_BROWSER_CHROMEOS_IDLE_DETECTOR_H_ | 6 #define CHROME_BROWSER_CHROMEOS_IDLE_DETECTOR_H_ |
7 | 7 |
8 #include "ash/wm/user_activity_observer.h" | 8 #include "ash/wm/user_activity_observer.h" |
9 #include "base/basictypes.h" | 9 #include "base/basictypes.h" |
| 10 #include "base/callback.h" |
10 #include "base/compiler_specific.h" | 11 #include "base/compiler_specific.h" |
| 12 #include "base/time/time.h" |
11 #include "base/timer/timer.h" | 13 #include "base/timer/timer.h" |
12 | 14 |
13 namespace chromeos { | 15 namespace chromeos { |
14 | 16 |
15 class IdleDetector : public ash::UserActivityObserver { | 17 class IdleDetector : public ash::UserActivityObserver { |
16 public: | 18 public: |
17 IdleDetector(const base::Closure& on_active_callback, | 19 IdleDetector(const base::Closure& on_active_callback, |
18 const base::Closure& on_idle_callback); | 20 const base::Closure& on_idle_callback); |
19 virtual ~IdleDetector(); | 21 virtual ~IdleDetector(); |
20 | 22 |
(...skipping 12 matching lines...) Expand all Loading... |
33 base::Closure idle_callback_; | 35 base::Closure idle_callback_; |
34 | 36 |
35 base::TimeDelta timeout_; | 37 base::TimeDelta timeout_; |
36 | 38 |
37 DISALLOW_COPY_AND_ASSIGN(IdleDetector); | 39 DISALLOW_COPY_AND_ASSIGN(IdleDetector); |
38 }; | 40 }; |
39 | 41 |
40 } // namespace chromeos | 42 } // namespace chromeos |
41 | 43 |
42 #endif // CHROME_BROWSER_CHROMEOS_IDLE_DETECTOR_H_ | 44 #endif // CHROME_BROWSER_CHROMEOS_IDLE_DETECTOR_H_ |
OLD | NEW |