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

Unified Diff: third_party/WebKit/Source/modules/sensor/OrientationSensor.cpp

Issue 2809743002: [Sensors] OrientationSensor.quaternion returns [x, y, z, w] (Closed)
Patch Set: rebased Created 3 years, 8 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 | « third_party/WebKit/LayoutTests/sensor/absolute-orientation-sensor.html ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/modules/sensor/OrientationSensor.cpp
diff --git a/third_party/WebKit/Source/modules/sensor/OrientationSensor.cpp b/third_party/WebKit/Source/modules/sensor/OrientationSensor.cpp
index 3d1cc1518c5a3d22aabd756d3eeabc6d211a03b8..a4d70a41e48a7abfe62c135cea48009c14c74493 100644
--- a/third_party/WebKit/Source/modules/sensor/OrientationSensor.cpp
+++ b/third_party/WebKit/Source/modules/sensor/OrientationSensor.cpp
@@ -15,10 +15,10 @@ Vector<double> OrientationSensor::quaternion(bool& is_null) {
reading_dirty_ = false;
is_null = !CanReturnReadings();
return is_null ? Vector<double>()
- : Vector<double>({ReadingValueUnchecked(3), // W
- ReadingValueUnchecked(0), // Vx
+ : Vector<double>({ReadingValueUnchecked(0), // Vx
ReadingValueUnchecked(1), // Vy
- ReadingValueUnchecked(2)}); // Vz
+ ReadingValueUnchecked(2), // Vz
+ ReadingValueUnchecked(3)}); // W
}
template <typename T>
« no previous file with comments | « third_party/WebKit/LayoutTests/sensor/absolute-orientation-sensor.html ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698