Loading media/java/android/media/AudioService.java +24 −30 Original line number Diff line number Diff line Loading @@ -1026,10 +1026,6 @@ public class AudioService extends IAudioService.Stub { return true; } mSoundPool = new SoundPool(NUM_SOUNDPOOL_CHANNELS, AudioSystem.STREAM_SYSTEM, 0); if (mSoundPool == null) { Log.w(TAG, "loadSoundEffects() could not allocate sound pool"); return false; } try { mSoundPoolCallBack = null; Loading Loading @@ -2104,7 +2100,6 @@ public class AudioService extends IAudioService.Stub { mSoundPool.play(SOUND_EFFECT_FILES_MAP[effectType][1], volFloat, volFloat, 0, 0, 1.0f); } else { MediaPlayer mediaPlayer = new MediaPlayer(); if (mediaPlayer != null) { try { String filePath = Environment.getRootDirectory() + SOUND_EFFECTS_PATH + SOUND_EFFECT_FILES[SOUND_EFFECT_FILES_MAP[effectType][0]]; mediaPlayer.setDataSource(filePath); Loading Loading @@ -2133,7 +2128,6 @@ public class AudioService extends IAudioService.Stub { } } } } private void onHandlePersistMediaButtonReceiver(ComponentName receiver) { Settings.System.putString(mContentResolver, Settings.System.MEDIA_BUTTON_RECEIVER, Loading media/java/android/media/SoundPool.java +4 −6 Original line number Diff line number Diff line Loading @@ -161,13 +161,11 @@ public class SoundPool int id = 0; try { File f = new File(path); if (f != null) { ParcelFileDescriptor fd = ParcelFileDescriptor.open(f, ParcelFileDescriptor.MODE_READ_ONLY); if (fd != null) { id = _load(fd.getFileDescriptor(), 0, f.length(), priority); fd.close(); } } } catch (java.io.IOException e) { Log.e(TAG, "error loading " + path); } Loading media/java/android/media/ThumbnailUtils.java +1 −3 Original line number Diff line number Diff line Loading @@ -472,9 +472,7 @@ public class ThumbnailUtils { byte [] thumbData = null; try { exif = new ExifInterface(filePath); if (exif != null) { thumbData = exif.getThumbnail(); } } catch (IOException ex) { Log.w(TAG, ex); } Loading Loading
media/java/android/media/AudioService.java +24 −30 Original line number Diff line number Diff line Loading @@ -1026,10 +1026,6 @@ public class AudioService extends IAudioService.Stub { return true; } mSoundPool = new SoundPool(NUM_SOUNDPOOL_CHANNELS, AudioSystem.STREAM_SYSTEM, 0); if (mSoundPool == null) { Log.w(TAG, "loadSoundEffects() could not allocate sound pool"); return false; } try { mSoundPoolCallBack = null; Loading Loading @@ -2104,7 +2100,6 @@ public class AudioService extends IAudioService.Stub { mSoundPool.play(SOUND_EFFECT_FILES_MAP[effectType][1], volFloat, volFloat, 0, 0, 1.0f); } else { MediaPlayer mediaPlayer = new MediaPlayer(); if (mediaPlayer != null) { try { String filePath = Environment.getRootDirectory() + SOUND_EFFECTS_PATH + SOUND_EFFECT_FILES[SOUND_EFFECT_FILES_MAP[effectType][0]]; mediaPlayer.setDataSource(filePath); Loading Loading @@ -2133,7 +2128,6 @@ public class AudioService extends IAudioService.Stub { } } } } private void onHandlePersistMediaButtonReceiver(ComponentName receiver) { Settings.System.putString(mContentResolver, Settings.System.MEDIA_BUTTON_RECEIVER, Loading
media/java/android/media/SoundPool.java +4 −6 Original line number Diff line number Diff line Loading @@ -161,13 +161,11 @@ public class SoundPool int id = 0; try { File f = new File(path); if (f != null) { ParcelFileDescriptor fd = ParcelFileDescriptor.open(f, ParcelFileDescriptor.MODE_READ_ONLY); if (fd != null) { id = _load(fd.getFileDescriptor(), 0, f.length(), priority); fd.close(); } } } catch (java.io.IOException e) { Log.e(TAG, "error loading " + path); } Loading
media/java/android/media/ThumbnailUtils.java +1 −3 Original line number Diff line number Diff line Loading @@ -472,9 +472,7 @@ public class ThumbnailUtils { byte [] thumbData = null; try { exif = new ExifInterface(filePath); if (exif != null) { thumbData = exif.getThumbnail(); } } catch (IOException ex) { Log.w(TAG, ex); } Loading