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

Commit b8b6a9a8 authored by Gloria Wang's avatar Gloria Wang
Browse files

To support uri started with http:// in some Java APIs

Fix for bug 4016388.

Change-Id: I9f6f449dca49eb03446bf6aa22b5dd467ca189c9
parent d7e80b9d
Loading
Loading
Loading
Loading
+5 −0
Original line number Diff line number Diff line
@@ -735,6 +735,7 @@ public class DrmManagerClient {
     * This method expects uri in the following format
     *     content://media/<table_name>/<row_index> (or)
     *     file://sdcard/test.mp4
     *     http://test.com/test.mp4
     *
     * Here <table_name> shall be "video" or "audio" or "images"
     * <row_index> the index of the content in given table
@@ -746,6 +747,10 @@ public class DrmManagerClient {
            if (null == scheme || scheme.equals("") ||
                    scheme.equals(ContentResolver.SCHEME_FILE)) {
                path = uri.getPath();

            } else if (scheme.equals("http")) {
                path = uri.toString();

            } else if (scheme.equals(ContentResolver.SCHEME_CONTENT)) {
                String[] projection = new String[] {MediaStore.MediaColumns.DATA};
                Cursor cursor = null;