diff options
author | Owen Lin <owenlin@google.com> | 2009-09-21 09:58:09 +0800 |
---|---|---|
committer | Owen Lin <owenlin@google.com> | 2009-09-21 09:58:09 +0800 |
commit | b6ad206f53981faee04800b787569dbb60492844 (patch) | |
tree | ebb0780e1816c0745eb5607b79e7ac1593bc1ae4 /src/com/android/camera/CameraSettings.java | |
parent | e7eee9b19ffeaf488b3965cca026f80c005740fc (diff) | |
download | LegacyCamera-b6ad206f53981faee04800b787569dbb60492844.zip LegacyCamera-b6ad206f53981faee04800b787569dbb60492844.tar.gz LegacyCamera-b6ad206f53981faee04800b787569dbb60492844.tar.bz2 |
Fix a bug that we didn't check if flash modes is supported by current device.
Change-Id: Iea47f6cba6f99975e0c463b9a52e69a8b6247eff
Diffstat (limited to 'src/com/android/camera/CameraSettings.java')
-rw-r--r-- | src/com/android/camera/CameraSettings.java | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/com/android/camera/CameraSettings.java b/src/com/android/camera/CameraSettings.java index 905c134..748d904 100644 --- a/src/com/android/camera/CameraSettings.java +++ b/src/com/android/camera/CameraSettings.java @@ -80,6 +80,8 @@ public class CameraSettings { (ListPreference) screen.findPreference(KEY_COLOR_EFFECT); ListPreference sceneMode = (ListPreference) screen.findPreference(KEY_SCENE_MODE); + ListPreference flashMode = + (ListPreference) screen.findPreference(KEY_FLASH_MODE); // Since the screen could be loaded from different resources, we need // to check if the preference is available here @@ -109,6 +111,10 @@ public class CameraSettings { filterUnsupportedOptions(screen, sceneMode, mParameters.getSupportedSceneModes()); } + if (flashMode != null) { + filterUnsupportedOptions(screen, + flashMode, mParameters.getSupportedFlashModes()); + } } private boolean removePreference(PreferenceGroup group, Preference remove) { |