diff options
author | Eino-Ville Talvala <etalvala@google.com> | 2012-01-06 15:46:36 -0800 |
---|---|---|
committer | Android (Google) Code Review <android-gerrit@google.com> | 2012-01-06 15:46:36 -0800 |
commit | 7944704e6c4cc10105838b78d3d8403bf66a066b (patch) | |
tree | ae87da85e5c8f7753d69ec8698a87138dcd0e6d0 /core | |
parent | a476eed6b291d06f5e571597b928b7b2f0b3f257 (diff) | |
parent | b7feb1c91f1053adb1815bc522c43db3f2c3f598 (diff) | |
download | frameworks_base-7944704e6c4cc10105838b78d3d8403bf66a066b.zip frameworks_base-7944704e6c4cc10105838b78d3d8403bf66a066b.tar.gz frameworks_base-7944704e6c4cc10105838b78d3d8403bf66a066b.tar.bz2 |
Merge "Switch camera sounds to always use the system enforced audio stream." into ics-mr1
Diffstat (limited to 'core')
-rw-r--r-- | core/java/android/hardware/CameraSound.java | 8 |
1 files changed, 1 insertions, 7 deletions
diff --git a/core/java/android/hardware/CameraSound.java b/core/java/android/hardware/CameraSound.java index 32de0cd..dc97ff0 100644 --- a/core/java/android/hardware/CameraSound.java +++ b/core/java/android/hardware/CameraSound.java @@ -110,7 +110,6 @@ public class CameraSound { private static class CameraSoundPlayer implements Runnable { private int mSoundId; - private int mAudioStreamType; private MediaPlayer mPlayer; private Thread mThread; private boolean mExit; @@ -147,7 +146,7 @@ public class CameraSound { } mPlayer = new MediaPlayer(); try { - mPlayer.setAudioStreamType(mAudioStreamType); + mPlayer.setAudioStreamType(AudioManager.STREAM_SYSTEM_ENFORCED); mPlayer.setDataSource(soundFilePath); mPlayer.setLooping(false); mPlayer.prepare(); @@ -179,11 +178,6 @@ public class CameraSound { public CameraSoundPlayer(int soundId) { mSoundId = soundId; - if (SystemProperties.get("ro.camera.sound.forced", "0").equals("0")) { - mAudioStreamType = AudioManager.STREAM_MUSIC; - } else { - mAudioStreamType = AudioManager.STREAM_SYSTEM_ENFORCED; - } } public void play() { |