Chromium Code Reviews| OLD | NEW |
|---|---|
| (Empty) | |
| 1 // Copyright 2016 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 #ifndef DEVICE_GENERIC_SENSOR_PLATFORM_SENSOR_PROVIDER_MAC_H_ | |
| 6 #define DEVICE_GENERIC_SENSOR_PLATFORM_SENSOR_PROVIDER_MAC_H_ | |
| 7 | |
| 8 #include "device/generic_sensor/platform_sensor_provider.h" | |
| 9 | |
| 10 namespace device { | |
| 11 | |
| 12 class SensorsPollingThreadMac; | |
| 13 | |
| 14 class PlatformSensorProviderMac : public PlatformSensorProvider { | |
| 15 public: | |
| 16 PlatformSensorProviderMac(); | |
| 17 ~PlatformSensorProviderMac() override; | |
| 18 | |
| 19 static PlatformSensorProviderMac* GetInstance(); | |
| 20 void BeginPollingSensor(PlatformSensor* sensor, | |
|
Mikhail
2016/09/13 09:27:35
this is not smth Provider should do (it's just a f
| |
| 21 const PlatformSensorConfiguration& configuration); | |
| 22 void StopPollingSensor(PlatformSensor* sensor); | |
| 23 | |
| 24 protected: | |
| 25 scoped_refptr<PlatformSensor> CreateSensorInternal( | |
| 26 mojom::SensorType type, | |
| 27 mojo::ScopedSharedBufferMapping mapping, | |
| 28 uint64_t buffer_size) override; | |
| 29 | |
| 30 private: | |
| 31 std::unique_ptr<SensorsPollingThreadMac> polling_thread_; | |
| 32 DISALLOW_COPY_AND_ASSIGN(PlatformSensorProviderMac); | |
| 33 }; | |
| 34 | |
| 35 } // namespace device | |
| 36 | |
| 37 #endif // DEVICE_GENERIC_SENSOR_PLATFORM_SENSOR_PROVIDER_MAC_H_ | |
| OLD | NEW |