OLD | NEW |
1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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 CONTENT_BROWSER_DEVICE_SENSORS_AMBIENT_LIGHT_MAC_H_ | 5 #ifndef CONTENT_BROWSER_DEVICE_SENSORS_AMBIENT_LIGHT_MAC_H_ |
6 #define CONTENT_BROWSER_DEVICE_SENSORS_AMBIENT_LIGHT_MAC_H_ | 6 #define CONTENT_BROWSER_DEVICE_SENSORS_AMBIENT_LIGHT_MAC_H_ |
7 | 7 |
8 #include <IOKit/IOKitLib.h> | 8 #include <IOKit/IOKitLib.h> |
| 9 #include <stdint.h> |
9 | 10 |
| 11 #include "base/macros.h" |
10 #include "base/memory/scoped_ptr.h" | 12 #include "base/memory/scoped_ptr.h" |
11 | 13 |
12 namespace content { | 14 namespace content { |
13 | 15 |
14 // Provides an interface to retrieve ambient light data from MacBooks. | 16 // Provides an interface to retrieve ambient light data from MacBooks. |
15 class AmbientLightSensor { | 17 class AmbientLightSensor { |
16 public: | 18 public: |
17 // Create AmbientLightSensor object, return NULL if no valid is sensor found. | 19 // Create AmbientLightSensor object, return NULL if no valid is sensor found. |
18 static scoped_ptr<AmbientLightSensor> Create(); | 20 static scoped_ptr<AmbientLightSensor> Create(); |
19 | 21 |
(...skipping 11 matching lines...) Expand all Loading... |
31 | 33 |
32 // IOKit connection to the local sensor. | 34 // IOKit connection to the local sensor. |
33 io_connect_t io_connection_; | 35 io_connect_t io_connection_; |
34 | 36 |
35 DISALLOW_COPY_AND_ASSIGN(AmbientLightSensor); | 37 DISALLOW_COPY_AND_ASSIGN(AmbientLightSensor); |
36 }; | 38 }; |
37 | 39 |
38 } // namespace content | 40 } // namespace content |
39 | 41 |
40 #endif // CONTENT_BROWSER_DEVICE_SENSORS_AMBIENT_LIGHT_MAC_H_ | 42 #endif // CONTENT_BROWSER_DEVICE_SENSORS_AMBIENT_LIGHT_MAC_H_ |
OLD | NEW |