Merge "Make sure the initial rotation is set" into gb-ub-photos-bryce
diff --git a/src/com/android/camera/ui/RotatableLayout.java b/src/com/android/camera/ui/RotatableLayout.java
index bf80605..2dea58d 100644
--- a/src/com/android/camera/ui/RotatableLayout.java
+++ b/src/com/android/camera/ui/RotatableLayout.java
@@ -62,6 +62,7 @@
@Override
public void onAttachedToWindow() {
+ mPrevRotation = Util.getDisplayRotation((Activity) getContext());
// check if there is any rotation before the view is attached to window
int currentOrientation = getResources().getConfiguration().orientation;
if (mInitialOrientation == currentOrientation) {
@@ -74,7 +75,6 @@
&& currentOrientation == Configuration.ORIENTATION_LANDSCAPE) {
rotateLayout(false);
}
- mPrevRotation = Util.getDisplayRotation((Activity) getContext());
}
@Override