From c97d23826a28dd725951eccb62651244f9fb8228 Mon Sep 17 00:00:00 2001
From: Wu-cheng Li <wuchengli@google.com>
Date: Wed, 15 Sep 2010 14:10:31 -0700
Subject: Update the code due to API change.

bug:3001395
bug:3001399
Change-Id: Ie1347ed28aa72a3ec637867dc2226c60ef2dbd6c
---
 src/com/android/camera/Camera.java         | 2 +-
 src/com/android/camera/CameraSettings.java | 2 +-
 src/com/android/camera/Util.java           | 2 +-
 3 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/src/com/android/camera/Camera.java b/src/com/android/camera/Camera.java
index 1c5ebed..c62fa22 100644
--- a/src/com/android/camera/Camera.java
+++ b/src/com/android/camera/Camera.java
@@ -785,7 +785,7 @@ public class Camera extends NoSearchActivity implements View.OnClickListener,
             int rotation = 0;
             if (mOrientation != OrientationEventListener.ORIENTATION_UNKNOWN) {
                 CameraInfo info = CameraHolder.instance().getCameraInfo()[mCameraId];
-                rotation = (mOrientation + info.mOrientation) % 360;
+                rotation = (mOrientation + info.orientation) % 360;
             }
             mParameters.setRotation(rotation);
 
diff --git a/src/com/android/camera/CameraSettings.java b/src/com/android/camera/CameraSettings.java
index 7743fd3..2c6bdf1 100644
--- a/src/com/android/camera/CameraSettings.java
+++ b/src/com/android/camera/CameraSettings.java
@@ -234,7 +234,7 @@ public class CameraSettings {
         int[] largeIconIds = new int[numOfCameras];
         for (int i = 0; i < numOfCameras; i++) {
             entryValues[i] = Integer.toString(i);
-            if (mCameraInfo[i].mFacing == CameraInfo.CAMERA_FACING_FRONT) {
+            if (mCameraInfo[i].facing == CameraInfo.CAMERA_FACING_FRONT) {
                 entries[i] = mContext.getString(
                         R.string.pref_camera_id_entry_front);
                 iconIds[i] = R.drawable.ic_menuselect_camera_facing_front;
diff --git a/src/com/android/camera/Util.java b/src/com/android/camera/Util.java
index c5de1f8..adf9152 100644
--- a/src/com/android/camera/Util.java
+++ b/src/com/android/camera/Util.java
@@ -298,7 +298,7 @@ public class Util {
                 new android.hardware.Camera.CameraInfo();
         android.hardware.Camera.getCameraInfo(cameraId, info);
         int degrees = getDisplayRotation(activity);
-        int result = (info.mOrientation - degrees + 360) % 360;
+        int result = (info.orientation - degrees + 360) % 360;
         camera.setDisplayOrientation(result);
     }
 }
-- 
cgit v1.1