Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit d9c6b163 authored by Sergey Volnov's avatar Sergey Volnov Committed by Automerger Merge Worker
Browse files

Merge "Add a comment to speech recognition service requiring clients targeting...

Merge "Add a comment to speech recognition service requiring clients targeting Android 11 to specify a <queries> tag." am: 8c682004 am: 507ca766 am: 9a4b4693

Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1660358

Change-Id: I4fb577b783a1fcc7b4817fc6fba9d8c56e14e5b5
parents 93a0dca3 9a4b4693
Loading
Loading
Loading
Loading
+23 −1
Original line number Diff line number Diff line
@@ -214,6 +214,17 @@ public class SpeechRecognizer {
     * command to the created {@code SpeechRecognizer}, otherwise no notifications will be
     * received.
     *
     * <p>For apps targeting Android 11 (API level 30) interaction with a speech recognition
     * service requires <queries> element to be added to the manifest file:
     * <pre>{@code
     * <queries>
     *   <intent>
     *     <action
     *        android:name="android.speech.RecognitionService" />
     *   </intent>
     * </queries>
     * }</pre>
     *
     * @param context in which to create {@code SpeechRecognizer}
     * @return a new {@code SpeechRecognizer}
     */
@@ -232,6 +243,17 @@ public class SpeechRecognizer {
     * {@link #createSpeechRecognizer(Context)} instead to use the system default recognition
     * service.
     *
     * <p>For apps targeting Android 11 (API level 30) interaction with a speech recognition
     * service requires <queries> element to be added to the manifest file:
     * <pre>{@code
     * <queries>
     *   <intent>
     *     <action
     *        android:name="android.speech.RecognitionService" />
     *   </intent>
     * </queries>
     * }</pre>
     *
     * @param context in which to create {@code SpeechRecognizer}
     * @param serviceComponent the {@link ComponentName} of a specific service to direct this
     *        {@code SpeechRecognizer} to