Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(4)

Side by Side Diff: device/generic_sensor/public/cpp/sensor_reading.cc

Issue 2395853003: [Sensors] Improvements in shared buffer managing (Closed)
Patch Set: Test compilation fix + comment from Ken Created 4 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
(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 #include "device/generic_sensor/public/cpp/sensor_reading.h"
6
7 namespace device {
8
9 SensorReading::SensorReading() = default;
10 SensorReading::SensorReading(const SensorReading& other) = default;
11 SensorReading::~SensorReading() = default;
12
13 SensorReadingSharedBuffer::SensorReadingSharedBuffer() = default;
14 SensorReadingSharedBuffer::~SensorReadingSharedBuffer() = default;
15
16 // static
17 uint64_t SensorReadingSharedBuffer::GetOffset(mojom::SensorType type) {
18 return (static_cast<uint64_t>(mojom::SensorType::LAST) -
19 static_cast<uint64_t>(type)) *
20 sizeof(SensorReadingSharedBuffer);
21 }
22
23 } // namespace device
OLDNEW
« no previous file with comments | « device/generic_sensor/public/cpp/sensor_reading.h ('k') | device/generic_sensor/public/interfaces/sensor_provider.mojom » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698