aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorandroid-build-team Robot <android-build-team-robot@google.com>2019-08-21 02:20:13 +0000
committerandroid-build-team Robot <android-build-team-robot@google.com>2019-08-21 02:20:13 +0000
commit6d43e27c0c7c23ce2b1784ca0c6d713c6e44115f (patch)
treeee1babded54b5d6d8f7e17d883d7e66c4fc97412
parent5c007cb0487c845f60c99cffdc3f0cb60d7852de (diff)
parent92e1f8896fa5511754d3bac95027240afd82d0b4 (diff)
downloadtests-android10-c2f2-s2-release.tar.gz
Change-Id: I72c9cd90777e22127f753bbd59dcd9a369cc25d3
-rw-r--r--TestMediaApp/AndroidManifest.xml14
-rw-r--r--TestMediaApp/res/drawable/ic_app_icon.xml15
-rw-r--r--TestMediaApp/res/mipmap-hdpi/ic_launcher_round.pngbin4208 -> 0 bytes
-rw-r--r--TestMediaApp/res/mipmap-mdpi/ic_launcher_round.pngbin2555 -> 0 bytes
-rw-r--r--TestMediaApp/res/mipmap-xhdpi/ic_launcher_round.pngbin6114 -> 0 bytes
-rw-r--r--TestMediaApp/res/mipmap-xxhdpi/ic_launcher_round.pngbin10056 -> 0 bytes
-rw-r--r--TestMediaApp/res/mipmap-xxxhdpi/ic_launcher_round.pngbin14696 -> 0 bytes
-rw-r--r--TestMediaApp/res/values/strings.xml2
-rw-r--r--TestMediaApp/src/com/android/car/media/testmediaapp/TmaBrowser2.java26
-rw-r--r--TestMediaApp/svgs/appIcon.svg90
10 files changed, 145 insertions, 2 deletions
diff --git a/TestMediaApp/AndroidManifest.xml b/TestMediaApp/AndroidManifest.xml
index 3639e9b..859815b 100644
--- a/TestMediaApp/AndroidManifest.xml
+++ b/TestMediaApp/AndroidManifest.xml
@@ -23,8 +23,6 @@
<application
android:allowBackup="true"
- android:icon="@mipmap/ic_launcher"
- android:roundIcon="@mipmap/ic_launcher_round"
android:label="@string/app_name"
android:supportsRtl="true"
android:theme="@style/TestMediaAppTheme" >
@@ -36,6 +34,7 @@
<service
android:name=".TmaBrowser"
+ android:icon="@drawable/ic_app_icon"
android:exported="true"
android:label="@string/app_name">
<intent-filter>
@@ -44,6 +43,17 @@
</intent-filter>
</service>
+ <service
+ android:name=".TmaBrowser2"
+ android:icon="@mipmap/ic_launcher"
+ android:exported="true"
+ android:label="@string/broken_service">
+ <intent-filter>
+ <action android:name="android.media.browse.MediaBrowserService" />
+ <action android:name="android.intent.action.MEDIA_BUTTON"/>
+ </intent-filter>
+ </service>
+
<activity
android:name=".prefs.TmaPrefsActivity"
android:label="@string/app_name">
diff --git a/TestMediaApp/res/drawable/ic_app_icon.xml b/TestMediaApp/res/drawable/ic_app_icon.xml
new file mode 100644
index 0000000..0985812
--- /dev/null
+++ b/TestMediaApp/res/drawable/ic_app_icon.xml
@@ -0,0 +1,15 @@
+<vector android:height="24dp" android:viewportHeight="33.86667"
+ android:viewportWidth="33.866665" android:width="24dp" xmlns:android="http://schemas.android.com/apk/res/android">
+ <path android:fillAlpha="1" android:fillColor="#6bfc00"
+ android:pathData="M5.0279,12.7651h23.2377v20.5024h-23.2377z"
+ android:strokeAlpha="1" android:strokeColor="#00000000" android:strokeWidth="0.26499999"/>
+ <path android:fillAlpha="1" android:fillColor="#6bfc00"
+ android:pathData="M5.143,12.5437a11.4907,8.1301 0,1 0,22.9814 0a11.4907,8.1301 0,1 0,-22.9814 0z"
+ android:strokeAlpha="1" android:strokeColor="#6bfc00" android:strokeWidth="0.49525586"/>
+ <path android:fillAlpha="1" android:fillColor="#002afc"
+ android:pathData="M10.3424,11.2542a1.0421,1.0942 0,1 0,2.0841 0a1.0421,1.0942 0,1 0,-2.0841 0z"
+ android:strokeAlpha="1" android:strokeColor="#00000000" android:strokeWidth="0.26499999"/>
+ <path android:fillAlpha="1" android:fillColor="#002afc"
+ android:pathData="M20.3461,11.3323a1.0421,1.0942 0,1 0,2.0841 0a1.0421,1.0942 0,1 0,-2.0841 0z"
+ android:strokeAlpha="1" android:strokeColor="#00000000" android:strokeWidth="0.26499999"/>
+</vector>
diff --git a/TestMediaApp/res/mipmap-hdpi/ic_launcher_round.png b/TestMediaApp/res/mipmap-hdpi/ic_launcher_round.png
deleted file mode 100644
index 9a078e3..0000000
--- a/TestMediaApp/res/mipmap-hdpi/ic_launcher_round.png
+++ /dev/null
Binary files differ
diff --git a/TestMediaApp/res/mipmap-mdpi/ic_launcher_round.png b/TestMediaApp/res/mipmap-mdpi/ic_launcher_round.png
deleted file mode 100644
index efc028a..0000000
--- a/TestMediaApp/res/mipmap-mdpi/ic_launcher_round.png
+++ /dev/null
Binary files differ
diff --git a/TestMediaApp/res/mipmap-xhdpi/ic_launcher_round.png b/TestMediaApp/res/mipmap-xhdpi/ic_launcher_round.png
deleted file mode 100644
index 3af2608..0000000
--- a/TestMediaApp/res/mipmap-xhdpi/ic_launcher_round.png
+++ /dev/null
Binary files differ
diff --git a/TestMediaApp/res/mipmap-xxhdpi/ic_launcher_round.png b/TestMediaApp/res/mipmap-xxhdpi/ic_launcher_round.png
deleted file mode 100644
index 9bec2e6..0000000
--- a/TestMediaApp/res/mipmap-xxhdpi/ic_launcher_round.png
+++ /dev/null
Binary files differ
diff --git a/TestMediaApp/res/mipmap-xxxhdpi/ic_launcher_round.png b/TestMediaApp/res/mipmap-xxxhdpi/ic_launcher_round.png
deleted file mode 100644
index 34947cd..0000000
--- a/TestMediaApp/res/mipmap-xxxhdpi/ic_launcher_round.png
+++ /dev/null
Binary files differ
diff --git a/TestMediaApp/res/values/strings.xml b/TestMediaApp/res/values/strings.xml
index 62ec9e1..ac621be 100644
--- a/TestMediaApp/res/values/strings.xml
+++ b/TestMediaApp/res/values/strings.xml
@@ -17,6 +17,8 @@
<resources>
<string name="app_name" translatable="false">Test Media App</string>
+ <string name="broken_service" translatable="false">Test Empty Media</string>
+
<string name="select_account" translatable="false">Please select an account type</string>
<string name="no_account" translatable="false"> A test account is required to use this test
diff --git a/TestMediaApp/src/com/android/car/media/testmediaapp/TmaBrowser2.java b/TestMediaApp/src/com/android/car/media/testmediaapp/TmaBrowser2.java
new file mode 100644
index 0000000..e42bb11
--- /dev/null
+++ b/TestMediaApp/src/com/android/car/media/testmediaapp/TmaBrowser2.java
@@ -0,0 +1,26 @@
+package com.android.car.media.testmediaapp;
+
+import android.os.Bundle;
+import android.support.v4.media.MediaBrowserCompat;
+
+import androidx.annotation.NonNull;
+import androidx.annotation.Nullable;
+import androidx.media.MediaBrowserServiceCompat;
+
+import java.util.List;
+
+/** Empty browser to test having two browsers in the apk. */
+public class TmaBrowser2 extends MediaBrowserServiceCompat {
+
+ @Nullable
+ @Override
+ public BrowserRoot onGetRoot(@NonNull String clientPackageName, int clientUid,
+ @Nullable Bundle rootHints) {
+ return null;
+ }
+
+ @Override
+ public void onLoadChildren(@NonNull String parentId,
+ @NonNull Result<List<MediaBrowserCompat.MediaItem>> result) {
+ }
+}
diff --git a/TestMediaApp/svgs/appIcon.svg b/TestMediaApp/svgs/appIcon.svg
new file mode 100644
index 0000000..fb81661
--- /dev/null
+++ b/TestMediaApp/svgs/appIcon.svg
@@ -0,0 +1,90 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<!-- Created with Inkscape (http://www.inkscape.org/) -->
+
+<svg
+ xmlns:dc="http://purl.org/dc/elements/1.1/"
+ xmlns:cc="http://creativecommons.org/ns#"
+ xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
+ xmlns:svg="http://www.w3.org/2000/svg"
+ xmlns="http://www.w3.org/2000/svg"
+ xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
+ xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
+ width="128"
+ height="128"
+ viewBox="0 0 33.866666 33.866668"
+ version="1.1"
+ id="svg8"
+ inkscape:version="0.92.3 (2405546, 2018-03-11)"
+ sodipodi:docname="appIcon.svg">
+ <defs
+ id="defs2" />
+ <sodipodi:namedview
+ id="base"
+ pagecolor="#ffffff"
+ bordercolor="#666666"
+ borderopacity="1.0"
+ inkscape:pageopacity="0.0"
+ inkscape:pageshadow="2"
+ inkscape:zoom="10.15625"
+ inkscape:cx="63.901538"
+ inkscape:cy="64"
+ inkscape:document-units="mm"
+ inkscape:current-layer="layer1"
+ showgrid="false"
+ units="px"
+ fit-margin-top="0"
+ fit-margin-left="0"
+ fit-margin-right="0"
+ fit-margin-bottom="0"
+ inkscape:window-width="2560"
+ inkscape:window-height="1526"
+ inkscape:window-x="0"
+ inkscape:window-y="26"
+ inkscape:window-maximized="1" />
+ <metadata
+ id="metadata5">
+ <rdf:RDF>
+ <cc:Work
+ rdf:about="">
+ <dc:format>image/svg+xml</dc:format>
+ <dc:type
+ rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
+ <dc:title></dc:title>
+ </cc:Work>
+ </rdf:RDF>
+ </metadata>
+ <g
+ inkscape:label="Layer 1"
+ inkscape:groupmode="layer"
+ id="layer1"
+ transform="translate(0,-263.13332)">
+ <rect
+ style="fill:#6bfc00;fill-opacity:1;stroke:none;stroke-width:0.26499999;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
+ id="rect815"
+ width="23.237743"
+ height="20.502357"
+ x="5.0278974"
+ y="275.89844" />
+ <ellipse
+ style="fill:#6bfc00;fill-opacity:1;stroke:#6bfc00;stroke-width:0.49525586;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
+ id="path828"
+ ry="8.1301022"
+ rx="11.490721"
+ cy="275.677"
+ cx="16.633743" />
+ <ellipse
+ style="fill:#002afc;fill-opacity:1;stroke:none;stroke-width:0.26499999;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
+ id="path832"
+ cx="11.38441"
+ cy="274.38748"
+ rx="1.0420513"
+ ry="1.0941538" />
+ <ellipse
+ style="fill:#002afc;fill-opacity:1;stroke:none;stroke-width:0.26499999;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
+ id="path832-3"
+ cx="21.388103"
+ cy="274.46561"
+ rx="1.0420513"
+ ry="1.0941539" />
+ </g>
+</svg>