summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/com/android/camera/settings/CameraSettingsActivity.java6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/com/android/camera/settings/CameraSettingsActivity.java b/src/com/android/camera/settings/CameraSettingsActivity.java
index 0429092c2..3fe75c628 100644
--- a/src/com/android/camera/settings/CameraSettingsActivity.java
+++ b/src/com/android/camera/settings/CameraSettingsActivity.java
@@ -147,6 +147,7 @@ public class CameraSettingsActivity extends FragmentActivity {
private String mPrefKey;
private boolean mHideAdvancedScreen;
private boolean mGetSubPrefAsRoot = true;
+ private boolean mPreferencesRemoved = false;
// Selected resolutions for the different cameras and sizes.
private PictureSizes mPictureSizes;
@@ -286,18 +287,19 @@ public class CameraSettingsActivity extends FragmentActivity {
private void setVisibilities() {
PreferenceGroup resolutions =
(PreferenceGroup) findPreference(PREF_CATEGORY_RESOLUTION);
- if (mPictureSizes.backCameraSizes.isEmpty()) {
+ if (mPictureSizes.backCameraSizes.isEmpty() && !mPreferencesRemoved) {
recursiveDelete(resolutions,
findPreference(Keys.KEY_PICTURE_SIZE_BACK));
recursiveDelete(resolutions,
findPreference(Keys.KEY_VIDEO_QUALITY_BACK));
}
- if (mPictureSizes.frontCameraSizes.isEmpty()) {
+ if (mPictureSizes.frontCameraSizes.isEmpty() && !mPreferencesRemoved) {
recursiveDelete(resolutions,
findPreference(Keys.KEY_PICTURE_SIZE_FRONT));
recursiveDelete(resolutions,
findPreference(Keys.KEY_VIDEO_QUALITY_FRONT));
}
+ mPreferencesRemoved = true;
}
/**