OSDN Git Service

Show Bliss logo as start button icon on Bliss-x86 devices
authorBraden Farmer <farmerbb@gmail.com>
Sat, 20 Jan 2018 17:53:32 +0000 (10:53 -0700)
committerBraden Farmer <farmerbb@gmail.com>
Sat, 20 Jan 2018 17:53:32 +0000 (10:53 -0700)
app/src/main/java/com/farmerbb/taskbar/service/TaskbarService.java
app/src/main/res/drawable/bliss.xml [new file with mode: 0644]

index 88cca08..fe79743 100644 (file)
@@ -304,14 +304,10 @@ public class TaskbarService extends Service {
         int padding;
 
         if(pref.getBoolean("app_drawer_icon", false)) {
-            if(U.hasSupportLibrary(this, 5)) {
-                try {
-                    startButton.setImageDrawable(getPackageManager().getApplicationIcon(BuildConfig.SUPPORT_APPLICATION_ID));
-                } catch (PackageManager.NameNotFoundException e) {
-                    startButton.setImageDrawable(ContextCompat.getDrawable(this, R.mipmap.ic_launcher));
-                }
-            } else
-                startButton.setImageDrawable(ContextCompat.getDrawable(this, R.mipmap.ic_launcher));
+            startButton.setImageDrawable(ContextCompat.getDrawable(this,
+                    U.hasSupportLibrary(this, 5)
+                            ? R.drawable.bliss
+                            : R.mipmap.ic_launcher));
 
             padding = getResources().getDimensionPixelSize(R.dimen.app_drawer_icon_padding_alt);
         } else {
diff --git a/app/src/main/res/drawable/bliss.xml b/app/src/main/res/drawable/bliss.xml
new file mode 100644 (file)
index 0000000..3e593c6
--- /dev/null
@@ -0,0 +1,34 @@
+<?xml version="1.0" encoding="utf-8"?>
+<vector xmlns:android="http://schemas.android.com/apk/res/android"
+    android:viewportWidth="92"
+    android:viewportHeight="92"
+    android:width="92dp"
+    android:height="92dp">
+    <group
+        android:scaleX="0.01471554"
+        android:scaleY="0.01471554"
+        android:translateX="-0.3733054"
+        android:translateY="15.37607">
+        <path
+            android:pathData="M3241.7 3992.9c50.5 -70.5 96.4 -135.9 143.5 -200.4 261.1 -357 545.5 -693.6 871.2 -993.8 278.8 -257 581.1 -480.6 921.9 -649.9 277.6 -137.8 570.1 -227.2 876.1 -273.8 41.3 -6.3 82.6 -12.9 123.5 -19.3 1.1 2.8 2.3 4.3 2 5.1 -82.8 173.1 -164.9 346.6 -248.9 519.1 -164.4 337.5 -362.1 654.2 -603.5 942.3 -75.5 90.1 -170.9 158.4 -270.4 220 -216.9 134.3 -453.7 220.5 -698.7 286.1 -301.5 80.8 -608.8 128.2 -919.7 152.8 -56.5 4.5 -113 7.9 -169.5 11.7 -7 0.5 -14.1 0.1 -27.5 0.1z"
+            android:fillColor="?android:attr/colorAccent" />
+        <path
+            android:pathData="M3043.3 3994.8c-58.6 -3.8 -110.9 -6.7 -163.3 -10.7 -306.9 -23.5 -610.6 -67.8 -909.1 -144.4 -240.4 -61.6 -473 -143.3 -690.1 -266 -175.9 -99.4 -318 -233.5 -439 -395.4C605.4 2862 414 2520.7 251.3 2162.1 205.3 2060.8 156.8 1960.7 108.4 1858c3.3 0 8.4 -0.5 13.3 0.1 598.7 71.4 1126.5 309.3 1599.1 678.5 351.3 274.5 659.1 592.3 936.2 940 129.1 162 249.1 331.3 373.1 497.3 3.7 4.6 6.4 9.8 13.2 20.9z"
+            android:fillColor="?android:attr/colorAccent" />
+        <path
+            android:pathData="M3102.5 3929c-9.8 -8.2 -19 -13.5 -24.9 -21.3 -123.5 -163.7 -245.2 -328.9 -370.5 -491.2 -58.3 -75.5 -121.6 -147.5 -186.3 -217.8 -111.7 -121.3 -224.7 -241.4 -340.1 -359.2 -64.6 -65.9 -135.3 -125.7 -202.6 -189.1 -8.6 -8.1 -15.4 -20.2 -18.7 -31.7 -98 -347.9 -126.5 -703.4 -114.2 -1063.1 7.6 -224.2 31.2 -446.6 74.4 -666.9 1.8 -9.1 3.8 -18.1 6.6 -30.9 9.4 6.6 17.1 11 23.7 16.6 167.7 141.5 309.5 306.5 436 484.9 300.2 423.1 493.3 892.9 606.4 1397.3 84.8 377.7 118.8 760.6 115.5 1147.2 0 4.7 -0.2 9.3 -0.7 14 -0.2 1.7 -1.4 3.4 -4.6 11.2z"
+            android:fillColor="?android:attr/colorAccent" />
+        <path
+            android:pathData="M3180.9 3931.6c-1.2 -14.2 -2 -19.4 -2 -24.7 -5 -457.7 43.5 -909 164.8 -1351.2 126.8 -462.3 324.1 -891.1 614.2 -1274.8 113.3 -149.8 237.7 -289.4 382.6 -409.8 4.1 -3.4 8.4 -6.5 12.8 -9.5 1 -0.7 2.5 -0.4 6.5 -0.9 1.8 7.1 4 14.4 5.4 21.9 67 346.6 91.3 696.1 72.1 1048.6 -12.6 230.3 -45.6 457.5 -108.8 679.6 -5.4 19.1 -19.1 37.7 -33.5 51.9 -32 31.7 -68 59.5 -100.5 90.8 -74.3 71.7 -150 142.2 -220.5 217.5 -103.9 111 -208.4 222 -304.5 339.6 -139.9 171 -272.7 347.8 -408.2 522.4 -18.3 23.6 -34 49.2 -51.9 73.1 -6.1 8.3 -15.4 14.1 -28.5 25.5z"
+            android:fillColor="?android:attr/colorAccent" />
+        <path
+            android:pathData="M3157.2 268c81.3 90 146.2 189 203.1 293.4 148 271.4 233.8 562.8 276.7 867.7 7.1 50.8 12.4 101.9 17.5 152.9 0.9 8.6 -1.2 18.8 -5.4 26.3 -76.7 135.7 -147.9 274.1 -204.3 419.6 -43 111 -86.1 222.1 -123.1 335.1 -55.9 171 -99.6 345.5 -129.3 523.1 -17 101.8 -31 204.1 -46.4 306.1 -0.2 1 -1.6 1.9 -4.1 4.6 -6 -42.9 -10.7 -84.3 -17.8 -125.4 -18.5 -107.6 -35.8 -215.5 -57.7 -322.4 -35.3 -172.6 -81.6 -342.6 -143.1 -507.6 -47.3 -127 -101.4 -251.5 -154.1 -376.3 -19.1 -45.3 -43.5 -88.3 -64.9 -132.7 -3 -6.2 -4.1 -14.2 -3.7 -21.2 21.6 -370.3 93.1 -729.4 242.5 -1070.7 54.7 -124.9 118.6 -244.7 200 -354.5 4.4 -5.8 9 -11.3 14.1 -18z"
+            android:fillColor="?android:attr/colorAccent" />
+        <path
+            android:pathData="M1859.3 2548.6c-56.8 -43.9 -109.7 -86.1 -163.8 -126.5 -135.5 -101.2 -276.1 -194.6 -425 -274.9 -56.2 -30.3 -113.8 -57.9 -170.2 -87.9 -9.7 -5.2 -19.5 -14.5 -24.1 -24.3C945 1756.7 855.4 1466.5 830.6 1158.5c-4.4 -54 -0.6 -108.7 -0.6 -165.7 9 2.8 19 5.1 28.4 8.8 155.7 61 296.2 148.8 430.3 247.2 171.9 126.2 327.6 270.6 472.7 426.6 8 8.6 13.4 23 13.9 34.9 1.6 44.6 -1.5 89.4 1.1 133.9 6.2 109.8 9.9 220.1 23.3 329.1 14.8 120 39.4 238.7 59.6 358 0.6 4.4 0 9.1 0 17.3z"
+            android:fillColor="?android:attr/colorAccent" />
+        <path
+            android:pathData="M5455.7 992c0.5 11 1.2 19.4 1.3 27.9 1.2 235.2 -43.9 462.8 -119.1 684.2 -37.9 111.5 -85.8 219.5 -130.9 328.5 -5.4 13 -19.1 25.8 -32.2 32 -181.4 86.3 -352.3 190.2 -514.9 307.7 -78.5 56.7 -155.1 116.1 -235.7 176.6 6.2 -30 13.1 -58.3 17.8 -86.9 15.6 -95.3 32.8 -190.5 44.7 -286.4 10.1 -81.4 15.5 -163.4 19.6 -245.4 3.8 -75.7 2.8 -151.6 4.8 -227.4 0.2 -9.1 3.2 -20.4 9.1 -26.8 198 -211.6 412.2 -404.4 662.6 -552.7 81.6 -48.3 170.1 -85.2 255.5 -127.1 4.2 -1.9 9 -2.2 17.4 -4.2z"
+            android:fillColor="?android:attr/colorAccent" />
+    </group>
+</vector>