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

Commit 8d616b45 authored by Zim's avatar Zim
Browse files

Add PROPERTY_MEDIA_CAPABILITIES API

This string allows apps add a media_capabilities.xml resource to the
AndroidManifest.xml

The media_capabilities.xml file will in turn allow apps declare the
media capabilities they support, so the OS can transcode unsupported
formats to compatible formats for the app

Note, that the hard-coded string is already in use in MediaProvider
and is covered by TranscodeTest mentioned below

Test: atest TranscodeTest
Bug: 178187121
Change-Id: I46cfaefe8fb7f0bbd14896efdee61dcc4da19783
parent 84199909
Loading
Loading
Loading
Loading
+1 −0
Original line number Original line Diff line number Diff line
@@ -12471,6 +12471,7 @@ package android.content.pm {
    field public static final long MAXIMUM_VERIFICATION_TIMEOUT = 3600000L; // 0x36ee80L
    field public static final long MAXIMUM_VERIFICATION_TIMEOUT = 3600000L; // 0x36ee80L
    field public static final int PERMISSION_DENIED = -1; // 0xffffffff
    field public static final int PERMISSION_DENIED = -1; // 0xffffffff
    field public static final int PERMISSION_GRANTED = 0; // 0x0
    field public static final int PERMISSION_GRANTED = 0; // 0x0
    field public static final String PROPERTY_MEDIA_CAPABILITIES = "android.media.PROPERTY_MEDIA_CAPABILITIES";
    field public static final int SIGNATURE_FIRST_NOT_SIGNED = -1; // 0xffffffff
    field public static final int SIGNATURE_FIRST_NOT_SIGNED = -1; // 0xffffffff
    field public static final int SIGNATURE_MATCH = 0; // 0x0
    field public static final int SIGNATURE_MATCH = 0; // 0x0
    field public static final int SIGNATURE_NEITHER_SIGNED = 1; // 0x1
    field public static final int SIGNATURE_NEITHER_SIGNED = 1; // 0x1
+13 −0
Original line number Original line Diff line number Diff line
@@ -124,6 +124,19 @@ public abstract class PackageManager {
        }
        }
    }
    }


    /**
     * <application> level {@link android.content.pm.PackageManager.Property} tag specifying
     * the XML resource ID containing an application's media capabilities XML file
     *
     * For example:
     * <application>
     *   <property android:name="android.media.PROPERTY_MEDIA_CAPABILITIES"
     *     android:resource="@xml/media_capabilities">
     * <application>
     */
    public static final String PROPERTY_MEDIA_CAPABILITIES =
            "android.media.PROPERTY_MEDIA_CAPABILITIES";

    /**
    /**
     * A property value set within the manifest.
     * A property value set within the manifest.
     * <p>
     * <p>