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

Unified Diff: device/sensors/sensor_manager_android.cc

Issue 2646093002: Move //content/browser/device_sensor/ into device/sensors (Closed)
Patch Set: gn format & code rebase Created 3 years, 11 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « device/sensors/sensor_manager_android.h ('k') | device/sensors/sensor_manager_android_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: device/sensors/sensor_manager_android.cc
diff --git a/content/browser/device_sensors/sensor_manager_android.cc b/device/sensors/sensor_manager_android.cc
similarity index 96%
rename from content/browser/device_sensors/sensor_manager_android.cc
rename to device/sensors/sensor_manager_android.cc
index 65f5771148e349e7d2c9e4e73edd62ae518a4bf0..0be733888c16c70005434d12cd8fc517e49aaf33 100644
--- a/content/browser/device_sensors/sensor_manager_android.cc
+++ b/device/sensors/sensor_manager_android.cc
@@ -2,7 +2,7 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-#include "content/browser/device_sensors/sensor_manager_android.h"
+#include "device/sensors/sensor_manager_android.h"
#include <string.h>
@@ -20,12 +20,13 @@ using base::android::JavaParamRef;
namespace {
void UpdateDeviceOrientationHistogram(
- content::SensorManagerAndroid::OrientationSensorType type) {
- UMA_HISTOGRAM_ENUMERATION("InertialSensor.DeviceOrientationSensorAndroid",
- type, content::SensorManagerAndroid::ORIENTATION_SENSOR_MAX);
+ device::SensorManagerAndroid::OrientationSensorType type) {
+ UMA_HISTOGRAM_ENUMERATION(
+ "InertialSensor.DeviceOrientationSensorAndroid", type,
+ device::SensorManagerAndroid::ORIENTATION_SENSOR_MAX);
}
-void SetOrientation(content::DeviceOrientationHardwareBuffer* buffer,
+void SetOrientation(device::DeviceOrientationHardwareBuffer* buffer,
double alpha, double beta, double gamma) {
buffer->seqlock.WriteBegin();
buffer->data.alpha = alpha;
@@ -37,9 +38,9 @@ void SetOrientation(content::DeviceOrientationHardwareBuffer* buffer,
buffer->seqlock.WriteEnd();
}
-void SetOrientationBufferStatus(
- content::DeviceOrientationHardwareBuffer* buffer,
- bool ready, bool absolute) {
+void SetOrientationBufferStatus(device::DeviceOrientationHardwareBuffer* buffer,
+ bool ready,
+ bool absolute) {
buffer->seqlock.WriteBegin();
buffer->data.absolute = absolute;
buffer->data.allAvailableSensorsAreActive = ready;
@@ -48,7 +49,7 @@ void SetOrientationBufferStatus(
} // namespace
-namespace content {
+namespace device {
SensorManagerAndroid::SensorManagerAndroid()
: number_active_device_motion_sensors_(0),
@@ -451,4 +452,4 @@ void SensorManagerAndroid::Shutdown() {
is_shutdown_ = true;
}
-} // namespace content
+} // namespace device
« no previous file with comments | « device/sensors/sensor_manager_android.h ('k') | device/sensors/sensor_manager_android_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698