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

Commit baaa71a1 authored by Faye Yan's avatar Faye Yan Committed by Android (Google) Code Review
Browse files

Merge " Create voice-activation permission" into main

parents 239520b9 61f814f4
Loading
Loading
Loading
Loading
+6 −3
Original line number Diff line number Diff line
@@ -2252,7 +2252,8 @@ public class AppOpsManager {
    public static final String OPSTR_USE_FULL_SCREEN_INTENT = "android:use_full_screen_intent";

    /**
     * Allows the assistant app to receive the PCC-validated hotword and be voice-triggered.
     * Allows the assistant app to be voice-triggered by detected hotwords from a trusted detection
     * service.
     *
     * @hide
     */
@@ -2379,7 +2380,8 @@ public class AppOpsManager {
            OP_RUN_USER_INITIATED_JOBS,
            OP_FOREGROUND_SERVICE_SPECIAL_USE,
            OP_CAPTURE_CONSENTLESS_BUGREPORT_ON_USERDEBUG_BUILD,
            OP_USE_FULL_SCREEN_INTENT
            OP_USE_FULL_SCREEN_INTENT,
            OP_RECEIVE_SANDBOX_TRIGGER_AUDIO
    };

    static final AppOpInfo[] sAppOpInfos = new AppOpInfo[]{
@@ -2810,7 +2812,8 @@ public class AppOpsManager {
        new AppOpInfo.Builder(OP_RECEIVE_SANDBOX_TRIGGER_AUDIO,
                OPSTR_RECEIVE_SANDBOX_TRIGGER_AUDIO,
                "RECEIVE_SANDBOX_TRIGGER_AUDIO")
                .setDefaultMode(AppOpsManager.MODE_ALLOWED).build(),
                .setPermission(Manifest.permission.RECEIVE_SANDBOX_TRIGGER_AUDIO)
                .setDefaultMode(AppOpsManager.MODE_DEFAULT).build(),
        new AppOpInfo.Builder(OP_RECEIVE_TRUSTED_PROCESS_TRAINING_DATA,
                OPSTR_RECEIVE_TRUSTED_PROCESS_TRAINING_DATA,
                "RECEIVE_TRUSTED_PROCESS_TRAINING_DATA").build()
+7 −0
Original line number Diff line number Diff line
@@ -7232,6 +7232,13 @@
                android:description="@string/permdesc_fullScreenIntent"
                android:protectionLevel="normal|appop" />

    <!-- Required for the assistant apps targeting {@link android.os.Build.VERSION_CODES#V}
         that receive voice trigger from the trusted hotword detection service.
         <p>Protection level: signature|privileged|appop
         @hide -->
    <permission android:name="android.permission.RECEIVE_SANDBOX_TRIGGER_AUDIO"
                android:protectionLevel="signature|privileged|appop" />

    <!-- @SystemApi Allows requesting the framework broadcast the
         {@link Intent#ACTION_DEVICE_CUSTOMIZATION_READY} intent.
         @hide -->