summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorjt1134 <jt1134@gmail.com>2014-01-20 19:45:13 +0200
committerChippa-a <vusal1372@gmail.com>2019-10-25 15:55:25 +0300
commit00ef53613ee536c6d52ea47c4c995801270fe142 (patch)
tree1a24208d891fa8f03532f9525f99e23bf91521e6
parent4ca2bae2b778f2ad6196c3b2fc67588b58de04b9 (diff)
downloadandroid_packages_apps_Snap-00ef53613ee536c6d52ea47c4c995801270fe142.tar.gz
android_packages_apps_Snap-00ef53613ee536c6d52ea47c4c995801270fe142.tar.bz2
android_packages_apps_Snap-00ef53613ee536c6d52ea47c4c995801270fe142.zip
Camera: separate settings for color effects
Author: jt1134 <jt1134@gmail.com> Date: Mon Jan 20 19:45:13 2014 +0200 Camera: separate settings for color effects Store color effect settings for the camera and video camera in their own separate preferences. Change-Id: I8faa59b8663154737910b338906d27f9736d5ad9 Author: Michael Bestas <mikeioannina@gmail.com> Date: Tue Aug 26 06:11:21 2014 +0300 Snap: Fix filtering of unsupported camcorder color effects Change-Id: I365deeb17995175db873f6799cf0cde43ee61e96 Change-Id: I7ee41923f8a7313eee06d5e0bf7e29a365d0af86
-rwxr-xr-xres/xml/video_preferences.xml2
-rwxr-xr-xsrc/com/android/camera/CameraSettings.java7
-rw-r--r--src/com/android/camera/VideoMenu.java4
-rw-r--r--src/com/android/camera/VideoModule.java2
4 files changed, 11 insertions, 4 deletions
diff --git a/res/xml/video_preferences.xml b/res/xml/video_preferences.xml
index 14c758b30..9d0f170bf 100755
--- a/res/xml/video_preferences.xml
+++ b/res/xml/video_preferences.xml
@@ -126,7 +126,7 @@
camera:largeIcons="@array/pref_filter_mode_icons"
camera:entryValues="@array/pref_camera_filter_mode_entryvalues" />
<IconListPreference
- camera:key="pref_camera_coloreffect_key"
+ camera:key="pref_camera_video_coloreffect_key"
camera:defaultValue="@string/pref_camera_coloreffect_default"
camera:title="@string/pref_camera_coloreffect_title"
camera:entries="@array/pref_camera_coloreffect_entries"
diff --git a/src/com/android/camera/CameraSettings.java b/src/com/android/camera/CameraSettings.java
index 9894480de..9dce35b6a 100755
--- a/src/com/android/camera/CameraSettings.java
+++ b/src/com/android/camera/CameraSettings.java
@@ -89,6 +89,7 @@ public class CameraSettings {
public static final String KEY_CAMERA_SAVEPATH = "pref_camera_savepath_key";
public static final String KEY_FILTER_MODE = "pref_camera_filter_mode_key";
public static final String KEY_COLOR_EFFECT = "pref_camera_coloreffect_key";
+ public static final String KEY_VIDEOCAMERA_COLOR_EFFECT = "pref_camera_video_coloreffect_key";
public static final String KEY_FACE_DETECTION = "pref_camera_facedetection_key";
public static final String KEY_TOUCH_AF_AEC = "pref_camera_touchafaec_key";
public static final String KEY_SELECTABLE_ZONE_AF = "pref_camera_selectablezoneaf_key";
@@ -752,6 +753,7 @@ public class CameraSettings {
ListPreference powerMode = group.findPreference(KEY_POWER_MODE);
ListPreference zsl = group.findPreference(KEY_ZSL);
ListPreference colorEffect = group.findPreference(KEY_COLOR_EFFECT);
+ ListPreference camcorderColorEffect = group.findPreference(KEY_VIDEOCAMERA_COLOR_EFFECT);
ListPreference faceDetection = group.findPreference(KEY_FACE_DETECTION);
ListPreference touchAfAec = group.findPreference(KEY_TOUCH_AF_AEC);
ListPreference selectableZoneAf = group.findPreference(KEY_SELECTABLE_ZONE_AF);
@@ -895,6 +897,11 @@ public class CameraSettings {
colorEffect, mParameters.getSupportedColorEffects());
}
+ if (camcorderColorEffect != null) {
+ filterUnsupportedOptions(group,
+ camcorderColorEffect, mParameters.getSupportedColorEffects());
+ }
+
if (aeBracketing != null) {
filterUnsupportedOptions(group,
aeBracketing, getSupportedAEBracketingModes(mParameters));
diff --git a/src/com/android/camera/VideoMenu.java b/src/com/android/camera/VideoMenu.java
index 330fa2ace..e891ce7af 100644
--- a/src/com/android/camera/VideoMenu.java
+++ b/src/com/android/camera/VideoMenu.java
@@ -508,7 +508,7 @@ public class VideoMenu extends MenuController
public void initFilterModeButton(View button) {
button.setVisibility(View.INVISIBLE);
final IconListPreference pref = (IconListPreference) mPreferenceGroup
- .findPreference(CameraSettings.KEY_COLOR_EFFECT);
+ .findPreference(CameraSettings.KEY_VIDEOCAMERA_COLOR_EFFECT);
if (pref == null || pref.getValue() == null)
return;
@@ -536,7 +536,7 @@ public class VideoMenu extends MenuController
public void addFilterMode() {
final IconListPreference pref = (IconListPreference) mPreferenceGroup
- .findPreference(CameraSettings.KEY_COLOR_EFFECT);
+ .findPreference(CameraSettings.KEY_VIDEOCAMERA_COLOR_EFFECT);
if (pref == null)
return;
diff --git a/src/com/android/camera/VideoModule.java b/src/com/android/camera/VideoModule.java
index 5734d174a..3d190e520 100644
--- a/src/com/android/camera/VideoModule.java
+++ b/src/com/android/camera/VideoModule.java
@@ -2334,7 +2334,7 @@ public class VideoModule implements CameraModule,
setZoomMenuValue();
String colorEffect = mPreferences.getString(
- CameraSettings.KEY_COLOR_EFFECT,
+ CameraSettings.KEY_VIDEOCAMERA_COLOR_EFFECT,
mActivity.getString(R.string.pref_camera_coloreffect_default));
Log.v(TAG, "Color effect value =" + colorEffect);
if (isSupported(colorEffect, mParameters.getSupportedColorEffects())) {