From f6de0f64af9231f71af7f02ce27b664a95be3f37 Mon Sep 17 00:00:00 2001 From: rostopira Date: Sun, 3 Dec 2023 13:34:03 +0200 Subject: [PATCH] material3 icons --- app/src/main/AndroidManifest.xml | 2 +- app/src/main/java/n/eus/wifiqs/SetupActivity.java | 2 +- app/src/main/java/n/eus/wifiqs/WifiTileService.java | 2 +- app/src/main/res/drawable/connected.xml | 9 --------- app/src/main/res/drawable/disabled.xml | 8 ++++---- app/src/main/res/drawable/enabled.xml | 6 +++--- app/src/main/res/drawable/rss_0.xml | 9 +++++++++ app/src/main/res/drawable/rss_1.xml | 9 +++++++++ app/src/main/res/drawable/rss_2.xml | 9 +++++++++ app/src/main/res/drawable/rss_3.xml | 9 +++++++++ app/src/main/res/drawable/rss_4.xml | 9 +++++++++ 11 files changed, 55 insertions(+), 19 deletions(-) delete mode 100644 app/src/main/res/drawable/connected.xml create mode 100644 app/src/main/res/drawable/rss_0.xml create mode 100644 app/src/main/res/drawable/rss_1.xml create mode 100644 app/src/main/res/drawable/rss_2.xml create mode 100644 app/src/main/res/drawable/rss_3.xml create mode 100644 app/src/main/res/drawable/rss_4.xml diff --git a/app/src/main/AndroidManifest.xml b/app/src/main/AndroidManifest.xml index d1b26ff..54fa83c 100644 --- a/app/src/main/AndroidManifest.xml +++ b/app/src/main/AndroidManifest.xml @@ -26,7 +26,7 @@ diff --git a/app/src/main/java/n/eus/wifiqs/SetupActivity.java b/app/src/main/java/n/eus/wifiqs/SetupActivity.java index 680293d..ca68ef9 100644 --- a/app/src/main/java/n/eus/wifiqs/SetupActivity.java +++ b/app/src/main/java/n/eus/wifiqs/SetupActivity.java @@ -55,7 +55,7 @@ public void onAddTileClicked(View button) { sbm.requestAddTileService( new ComponentName(BuildConfig.APPLICATION_ID, BuildConfig.APPLICATION_ID + ".WifiTileService"), getString(R.string.wifi), - Icon.createWithResource(this, R.drawable.connected), + Icon.createWithResource(this, R.drawable.rss_4), getMainExecutor(), resultCode -> {} ); diff --git a/app/src/main/java/n/eus/wifiqs/WifiTileService.java b/app/src/main/java/n/eus/wifiqs/WifiTileService.java index c962833..56ecb05 100644 --- a/app/src/main/java/n/eus/wifiqs/WifiTileService.java +++ b/app/src/main/java/n/eus/wifiqs/WifiTileService.java @@ -45,7 +45,7 @@ public void onWifiStateChanged(WifiState state, String ssid) { tile.setState(Tile.STATE_ACTIVE); break; case CONNECTED: - tile.setIcon(Icon.createWithResource(this, R.drawable.connected)); + tile.setIcon(Icon.createWithResource(this, R.drawable.rss_4)); if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.Q) { tile.setLabel(getString(R.string.wifi)); tile.setSubtitle(ssid != null ? ssid : getString(R.string.connected)); diff --git a/app/src/main/res/drawable/connected.xml b/app/src/main/res/drawable/connected.xml deleted file mode 100644 index 44a856d..0000000 --- a/app/src/main/res/drawable/connected.xml +++ /dev/null @@ -1,9 +0,0 @@ - - - diff --git a/app/src/main/res/drawable/disabled.xml b/app/src/main/res/drawable/disabled.xml index 0cb18b8..ad5854f 100644 --- a/app/src/main/res/drawable/disabled.xml +++ b/app/src/main/res/drawable/disabled.xml @@ -1,9 +1,9 @@ + android:viewportWidth="960" + android:viewportHeight="960"> + android:fillColor="#FFF" + android:pathData="m717,603 l-57,-57 184,-184q-79,-60 -172,-91t-192,-31q-29,0 -58,3t-58,8l-66,-66q45,-12 90,-18.5t92,-6.5q136,0 260.5,51.5T960,360L717,603ZM480,726l67,-66 -350,-350q-21,11 -41,24.5T116,362l364,364ZM819,932 L604,716 480,840 0,360q32,-32 66.5,-59t72.5,-49L27,140l57,-57L876,875l-57,57ZM512,398ZM372,485Z"/> diff --git a/app/src/main/res/drawable/enabled.xml b/app/src/main/res/drawable/enabled.xml index 27c5144..bed88ee 100644 --- a/app/src/main/res/drawable/enabled.xml +++ b/app/src/main/res/drawable/enabled.xml @@ -1,9 +1,9 @@ + android:viewportWidth="960" + android:viewportHeight="960"> + android:pathData="M480,840 L0,360q95,-97 219.5,-148.5T480,160q136,0 260.5,51.5T960,360L480,840Z"/> diff --git a/app/src/main/res/drawable/rss_0.xml b/app/src/main/res/drawable/rss_0.xml new file mode 100644 index 0000000..51be097 --- /dev/null +++ b/app/src/main/res/drawable/rss_0.xml @@ -0,0 +1,9 @@ + + + diff --git a/app/src/main/res/drawable/rss_1.xml b/app/src/main/res/drawable/rss_1.xml new file mode 100644 index 0000000..e337986 --- /dev/null +++ b/app/src/main/res/drawable/rss_1.xml @@ -0,0 +1,9 @@ + + + diff --git a/app/src/main/res/drawable/rss_2.xml b/app/src/main/res/drawable/rss_2.xml new file mode 100644 index 0000000..b601884 --- /dev/null +++ b/app/src/main/res/drawable/rss_2.xml @@ -0,0 +1,9 @@ + + + diff --git a/app/src/main/res/drawable/rss_3.xml b/app/src/main/res/drawable/rss_3.xml new file mode 100644 index 0000000..aed88a8 --- /dev/null +++ b/app/src/main/res/drawable/rss_3.xml @@ -0,0 +1,9 @@ + + + diff --git a/app/src/main/res/drawable/rss_4.xml b/app/src/main/res/drawable/rss_4.xml new file mode 100644 index 0000000..db57070 --- /dev/null +++ b/app/src/main/res/drawable/rss_4.xml @@ -0,0 +1,9 @@ + + +