| 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 DEVICE_SENSORS_DEVICE_SENSOR_SERVICE_H_ | 5 #ifndef DEVICE_SENSORS_DEVICE_SENSOR_SERVICE_H_ |
| 6 #define DEVICE_SENSORS_DEVICE_SENSOR_SERVICE_H_ | 6 #define DEVICE_SENSORS_DEVICE_SENSOR_SERVICE_H_ |
| 7 | 7 |
| 8 #include <memory> | 8 #include <memory> |
| 9 | 9 |
| 10 #include "base/callback_forward.h" | 10 #include "base/callback_forward.h" |
| (...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 55 | 55 |
| 56 private: | 56 private: |
| 57 friend struct base::DefaultSingletonTraits<DeviceSensorService>; | 57 friend struct base::DefaultSingletonTraits<DeviceSensorService>; |
| 58 | 58 |
| 59 DeviceSensorService(); | 59 DeviceSensorService(); |
| 60 ~DeviceSensorService() override; | 60 ~DeviceSensorService() override; |
| 61 | 61 |
| 62 bool ChangeNumberConsumers(ConsumerType consumer_type, int delta); | 62 bool ChangeNumberConsumers(ConsumerType consumer_type, int delta); |
| 63 int GetNumberConsumers(ConsumerType consumer_type) const; | 63 int GetNumberConsumers(ConsumerType consumer_type) const; |
| 64 | 64 |
| 65 int num_light_readers_; | |
| 66 int num_motion_readers_; | 65 int num_motion_readers_; |
| 67 int num_orientation_readers_; | 66 int num_orientation_readers_; |
| 68 int num_orientation_absolute_readers_; | 67 int num_orientation_absolute_readers_; |
| 69 bool is_shutdown_; | 68 bool is_shutdown_; |
| 70 std::unique_ptr<DataFetcherSharedMemory> data_fetcher_; | 69 std::unique_ptr<DataFetcherSharedMemory> data_fetcher_; |
| 71 base::ThreadChecker thread_checker_; | 70 base::ThreadChecker thread_checker_; |
| 72 | 71 |
| 73 DISALLOW_COPY_AND_ASSIGN(DeviceSensorService); | 72 DISALLOW_COPY_AND_ASSIGN(DeviceSensorService); |
| 74 }; | 73 }; |
| 75 | 74 |
| 76 } // namespace device | 75 } // namespace device |
| 77 | 76 |
| 78 #endif // DEVICE_SENSORS_DEVICE_SENSOR_SERVICE_H_ | 77 #endif // DEVICE_SENSORS_DEVICE_SENSOR_SERVICE_H_ |
| OLD | NEW |