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

Commit 9a4b4693 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

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

Change-Id: I4e28f341625e890a2342ebdb13fdfad09832dcc6
parents b139c0e7 507ca766
Loading
Loading
Loading
Loading
+23 −1
Original line number Diff line number Diff line
@@ -205,6 +205,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}
     */
@@ -223,6 +234,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