summaryrefslogtreecommitdiffstats
path: root/src/com/android/camera/PhotoUI.java
diff options
context:
space:
mode:
authorMichael Kolb <kolby@google.com>2013-06-24 13:22:52 -0700
committerAlan Newberger <alann@google.com>2013-12-03 10:20:52 -0800
commit13350e5e46db241b4f6d1ad3f371ac7292c12e65 (patch)
treedcd90b67b882b434bfb8f5e481c13b09db76c8dc /src/com/android/camera/PhotoUI.java
parent0f7d5488d33988c1ee3636fe3a7d6472bed84f00 (diff)
downloadandroid_packages_apps_Snap-13350e5e46db241b4f6d1ad3f371ac7292c12e65.tar.gz
android_packages_apps_Snap-13350e5e46db241b4f6d1ad3f371ac7292c12e65.tar.bz2
android_packages_apps_Snap-13350e5e46db241b4f6d1ad3f371ac7292c12e65.zip
Fix WB indicator override
Patching into Carlsbad from Bryce. Bug: 9372794 Change-Id: I4f23f05ca1acaef84a24034237e82001aac09f78
Diffstat (limited to 'src/com/android/camera/PhotoUI.java')
-rw-r--r--src/com/android/camera/PhotoUI.java9
1 files changed, 6 insertions, 3 deletions
diff --git a/src/com/android/camera/PhotoUI.java b/src/com/android/camera/PhotoUI.java
index 8308e1561..5018c16d6 100644
--- a/src/com/android/camera/PhotoUI.java
+++ b/src/com/android/camera/PhotoUI.java
@@ -526,12 +526,15 @@ public class PhotoUI implements PieListener,
mOnScreenIndicators.updateExposureOnScreenIndicator(params,
CameraSettings.readExposure(prefs));
mOnScreenIndicators.updateFlashOnScreenIndicator(params.getFlashMode());
- int wbIndex = 2;
+ int wbIndex = -1;
+ String wb = params.getWhiteBalance();
ListPreference pref = group.findPreference(CameraSettings.KEY_WHITE_BALANCE);
if (pref != null) {
- wbIndex = pref.getCurrentIndex();
+ wbIndex = pref.findIndexOfValue(wb);
}
- mOnScreenIndicators.updateWBIndicator(wbIndex);
+ // make sure the correct value was found
+ // otherwise use auto index
+ mOnScreenIndicators.updateWBIndicator(wbIndex < 0 ? 2 : wbIndex);
boolean location = RecordLocationPreference.get(
prefs, mActivity.getContentResolver());
mOnScreenIndicators.updateLocationIndicator(location);