diff options
| author | 2022-03-18 15:50:23 +0000 | |
|---|---|---|
| committer | 2022-03-18 15:50:23 +0000 | |
| commit | d44a439edf9dd56196f0b2e49e6106f267b2ef1d (patch) | |
| tree | b4ab3206547daf8e7b42d6d6dcc18f221c117ef7 | |
| parent | 0fa758c3b8a4d3c0d4e51d72f70b4d26c52fda6a (diff) | |
| parent | 2f04f34eb3c3ddd864c4c482ad46c3c499cf6ab2 (diff) | |
Merge "Add recommendation to use MediaActionSound class in a background thread since it relies on binder." am: 23398e75a3 am: 2f04f34eb3
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/2025024
Change-Id: I442624d1391a7f45d2508145cd9c32c42605f445
| -rw-r--r-- | media/java/android/media/MediaActionSound.java | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/media/java/android/media/MediaActionSound.java b/media/java/android/media/MediaActionSound.java index ec56d614f2b5..ad1405aa2356 100644 --- a/media/java/android/media/MediaActionSound.java +++ b/media/java/android/media/MediaActionSound.java @@ -25,7 +25,8 @@ import android.util.Log; /** * <p>A class for producing sounds that match those produced by various actions - * taken by the media and camera APIs. </p> + * taken by the media and camera APIs. It is recommended to call methods in this class + * in a background thread since it relies on binder calls.</p> * * <p>This class is recommended for use with the {@link android.hardware.camera2} API, since the * camera2 API does not play any sounds on its own for any capture or video recording actions.</p> @@ -109,7 +110,7 @@ public class MediaActionSound { /** * <p>Returns true if the application must play the shutter sound in accordance - * to certain regional restrictions. </p> + * to certain regional restrictions.</p> * * <p>If this method returns true, applications are strongly recommended to use * MediaActionSound.play(SHUTTER_CLICK) or START_VIDEO_RECORDING whenever it captures |