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

Unified Diff: content/public/android/java/src/org/chromium/content/browser/DeviceOrientation.java

Issue 10854182: Fix alpha value for device orientation (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 4 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 | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/public/android/java/src/org/chromium/content/browser/DeviceOrientation.java
diff --git a/content/public/android/java/src/org/chromium/content/browser/DeviceOrientation.java b/content/public/android/java/src/org/chromium/content/browser/DeviceOrientation.java
index d149a12cc9c30ac9440c119102141da6e2ad7d1d..1144135509d0adf53260d5cb704cfa06d3df453e 100644
--- a/content/public/android/java/src/org/chromium/content/browser/DeviceOrientation.java
+++ b/content/public/android/java/src/org/chromium/content/browser/DeviceOrientation.java
@@ -131,7 +131,7 @@ class DeviceOrientation implements SensorEventListener {
float[] rotationAngles = new float[3];
SensorManager.getOrientation(deviceRotationMatrix, rotationAngles);
- double alpha = Math.toDegrees(-rotationAngles[0]) - 90.0;
+ double alpha = Math.toDegrees(-rotationAngles[0]);
while (alpha < 0.0) {
alpha += 360.0; // [0, 360)
}
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698