| OLD | NEW |
| 1 // Copyright 2016 The Chromium Authors. All rights reserved. | 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 | 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 #include "device/generic_sensor/sensor_impl.h" | 5 #include "services/device/generic_sensor/sensor_impl.h" |
| 6 | 6 |
| 7 #include <utility> | 7 #include <utility> |
| 8 | 8 |
| 9 #include "mojo/public/cpp/bindings/strong_binding.h" | 9 #include "mojo/public/cpp/bindings/strong_binding.h" |
| 10 | 10 |
| 11 namespace device { | 11 namespace device { |
| 12 | 12 |
| 13 SensorImpl::SensorImpl(scoped_refptr<PlatformSensor> sensor) | 13 SensorImpl::SensorImpl(scoped_refptr<PlatformSensor> sensor) |
| 14 : sensor_(std::move(sensor)), suspended_(false) { | 14 : sensor_(std::move(sensor)), suspended_(false) { |
| 15 sensor_->AddClient(this); | 15 sensor_->AddClient(this); |
| (...skipping 46 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 62 DCHECK(!suspended_); | 62 DCHECK(!suspended_); |
| 63 if (client_) | 63 if (client_) |
| 64 client_->RaiseError(); | 64 client_->RaiseError(); |
| 65 } | 65 } |
| 66 | 66 |
| 67 bool SensorImpl::IsNotificationSuspended() { | 67 bool SensorImpl::IsNotificationSuspended() { |
| 68 return suspended_; | 68 return suspended_; |
| 69 } | 69 } |
| 70 | 70 |
| 71 } // namespace device | 71 } // namespace device |
| OLD | NEW |