From d5d9aa897cd285af2d02d091a49fabb83430d20e Mon Sep 17 00:00:00 2001 From: Isira Seneviratne Date: Fri, 25 Sep 2020 16:20:26 +0530 Subject: [PATCH] Replace expand PNGs with vector drawables. --- .../views/AppDetailsRecyclerViewAdapter.java | 6 +++--- .../res/drawable-hdpi/ic_expand_less_grey600.png | Bin 151 -> 0 bytes .../res/drawable-hdpi/ic_expand_more_grey600.png | Bin 152 -> 0 bytes .../res/drawable-mdpi/ic_expand_less_grey600.png | Bin 128 -> 0 bytes .../res/drawable-mdpi/ic_expand_more_grey600.png | Bin 126 -> 0 bytes .../res/drawable-xhdpi/ic_expand_less_grey600.png | Bin 173 -> 0 bytes .../res/drawable-xhdpi/ic_expand_more_grey600.png | Bin 178 -> 0 bytes .../drawable-xxhdpi/ic_expand_less_grey600.png | Bin 215 -> 0 bytes .../drawable-xxhdpi/ic_expand_more_grey600.png | Bin 219 -> 0 bytes .../drawable-xxxhdpi/ic_expand_less_grey600.png | Bin 262 -> 0 bytes .../drawable-xxxhdpi/ic_expand_more_grey600.png | Bin 270 -> 0 bytes app/src/main/res/drawable/ic_expand_less.xml | 5 +++++ app/src/main/res/drawable/ic_expand_more.xml | 5 +++++ app/src/main/res/layout/app_details2_links.xml | 4 ++-- .../main/res/layout/app_details2_version_item.xml | 2 +- 15 files changed, 16 insertions(+), 6 deletions(-) delete mode 100644 app/src/main/res/drawable-hdpi/ic_expand_less_grey600.png delete mode 100644 app/src/main/res/drawable-hdpi/ic_expand_more_grey600.png delete mode 100644 app/src/main/res/drawable-mdpi/ic_expand_less_grey600.png delete mode 100644 app/src/main/res/drawable-mdpi/ic_expand_more_grey600.png delete mode 100644 app/src/main/res/drawable-xhdpi/ic_expand_less_grey600.png delete mode 100644 app/src/main/res/drawable-xhdpi/ic_expand_more_grey600.png delete mode 100644 app/src/main/res/drawable-xxhdpi/ic_expand_less_grey600.png delete mode 100644 app/src/main/res/drawable-xxhdpi/ic_expand_more_grey600.png delete mode 100644 app/src/main/res/drawable-xxxhdpi/ic_expand_less_grey600.png delete mode 100644 app/src/main/res/drawable-xxxhdpi/ic_expand_more_grey600.png create mode 100644 app/src/main/res/drawable/ic_expand_less.xml create mode 100644 app/src/main/res/drawable/ic_expand_more.xml diff --git a/app/src/main/java/org/fdroid/fdroid/views/AppDetailsRecyclerViewAdapter.java b/app/src/main/java/org/fdroid/fdroid/views/AppDetailsRecyclerViewAdapter.java index 707fb09a7..95f1a410d 100644 --- a/app/src/main/java/org/fdroid/fdroid/views/AppDetailsRecyclerViewAdapter.java +++ b/app/src/main/java/org/fdroid/fdroid/views/AppDetailsRecyclerViewAdapter.java @@ -842,8 +842,8 @@ public class AppDetailsRecyclerViewAdapter iconDrawable = DrawableCompat.wrap(iconDrawable).mutate(); DrawableCompat.setTint(iconDrawable, Color.parseColor("#B4B4B4")); } - final Drawable expandLess = ContextCompat.getDrawable(headerView.getContext(), R.drawable.ic_expand_less_grey600); - final Drawable expandMore = ContextCompat.getDrawable(headerView.getContext(), R.drawable.ic_expand_more_grey600); + final Drawable expandLess = ContextCompat.getDrawable(headerView.getContext(), R.drawable.ic_expand_less); + final Drawable expandMore = ContextCompat.getDrawable(headerView.getContext(), R.drawable.ic_expand_more); TextViewCompat.setCompoundDrawablesRelativeWithIntrinsicBounds(headerView, iconDrawable, null, isExpanded ? expandLess : expandMore, null); } @@ -1300,7 +1300,7 @@ public class AppDetailsRecyclerViewAdapter expandedLayout.setVisibility(expand ? View.VISIBLE : View.GONE); versionCode.setVisibility(expand ? View.VISIBLE : View.GONE); expandArrow.setImageDrawable(ContextCompat.getDrawable(context, expand ? - R.drawable.ic_expand_less_grey600 : R.drawable.ic_expand_more_grey600)); + R.drawable.ic_expand_less : R.drawable.ic_expand_more)); // This is required to make these labels // auto-scrollable when they are too long diff --git a/app/src/main/res/drawable-hdpi/ic_expand_less_grey600.png b/app/src/main/res/drawable-hdpi/ic_expand_less_grey600.png deleted file mode 100644 index 2108ad2c091a8e1470df026146ed69197927341b..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 151 zcmeAS@N?(olHy`uVBq!ia0vp^Dj>|k0wldT1B8K8oTrOpNCo5DbB$~b2|PzW3VuDp zyku|C)!$b+4j-J;f9Nm2L0y{H%Kc9s8n*2$Hf(vQk&wYPL)$(0=p4J>hXM{n91A=u zqu(rYS|G%++R!2Q@B9gxSzGJuO!efKOsQgcdphs@1PdWApiK;(u6{1-oD!M|k0wldT1B8K8yr+v}NCo5DGlpCZ1|kP8G&$`p z_|_F3^tJ5%M(@^~*t%;6w2e=1>UsKo&C%lrJ!R+hPEVUTS7FBrXEhGbiye$tXYysf zT2|#2*d{n7iRG(@TfjWQDTyqq5{{*5Ws%cr)710D%dh?n2U^A8>FVdQ&MBb@0H(Ay A?*IS* diff --git a/app/src/main/res/drawable-mdpi/ic_expand_less_grey600.png b/app/src/main/res/drawable-mdpi/ic_expand_less_grey600.png deleted file mode 100644 index a91d298707a75ed5551041aa5f717dc2f2ceed3e..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 128 zcmeAS@N?(olHy`uVBq!ia0vp^5+KaM0wlfaz7_*1cTX3`kP60Ri8BczQ_QBAO<4BF zUchX^qCflshqelY{o8G_#zbaOtH)CXGav56rwaw-oVew99iA!%@Hu(Q+F5Ve(81$m az{T+DmfFS$kP61P=Qr{;81T3R=Ckso zxio(`ae!&UqgT#HB22#Dar-Y)?eF4p3NZkP61PXBpX;97I|kmaooz z8P$A4YgfTb27RZ*4Lyo8-ZT7<7Zen%Z*Ps1ws^GU+4~F|L-U{FQs$=j=O0a+oS*qo z_CwR>-fY9#hbKNKaa1NA{OJv3pZ)x(@nGfmN7L=a4RzjB#{KxbC&JZ-yMCUylbw>% aBVNsxJpr;>X}5rmVDNPHb6Mw<&;$S&X+)O* diff --git a/app/src/main/res/drawable-xxhdpi/ic_expand_less_grey600.png b/app/src/main/res/drawable-xxhdpi/ic_expand_less_grey600.png deleted file mode 100644 index b4db0591975b4478b05b9fcf0ac3c5d30fc52aa3..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 215 zcmeAS@N?(olHy`uVBq!ia0vp^9w5xY0wn)GsXhaw=6Sj}hEy=Vy}Xh45CaeEMV|vK zjkGabgB)FL11(Jify;*x;J0vTVm4gQOP&?lZ@I^OP^WK z4K&Z6oIK(4n(!GcbGBa7;j}ot-GtL3Qm9~;mAmH=$DnzKm*_0_%vU;FJj3MtOl89k zOP{JUZ&p}F#Lf!&-l%Q$#Negbr*w81wb^qX{U46uiCSE>Z{9>%r;++n57u~Y3^(TBiuJ@v?_0d0 zX8SFAV!d$E>my#vCTs8X+h=0Eank!I-kXJWZ-O{KC%shhmYr(@vh@IS;n{iLYu9B> P1Mxgv{an^LB{Ts5rcqv> diff --git a/app/src/main/res/drawable-xxxhdpi/ic_expand_less_grey600.png b/app/src/main/res/drawable-xxxhdpi/ic_expand_less_grey600.png deleted file mode 100644 index f907e97c59415676d18e80bb1a6e06c8832064c1..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 262 zcmeAS@N?(olHy`uVBq!ia0vp^2_VeD0wg^q?%xcg&U(5yhEy=Vz3Rxv=pf*7(UPJ3 ziNI##FLxhAomuzBJH+be`tP5#5Agt%f&f}_TjJX@r^UrbFN?SAJzC@@#$^hum`Fj@ktfk=TDid f&tZePjN#S~hJy1q_stZz0CugXtDnm{r-UW|=^<~g diff --git a/app/src/main/res/drawable-xxxhdpi/ic_expand_more_grey600.png b/app/src/main/res/drawable-xxxhdpi/ic_expand_more_grey600.png deleted file mode 100644 index e3c993ee75493db4b983ffaf198f7c9147d95c39..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 270 zcmeAS@N?(olHy`uVBq!ia0vp^2_VeD0wg^q?%xcgu6nvShEy=VJ%7-Y!GVGK;@)O8 zO-1#Fw>%fFS}`4{&^NH>^*Q!l(Q}dt7%h2|nq8o5eKYsT`86@A-Orz!X{-1CDXnLG zreDDL1@#&ku9|ttm*{Jpa7@ zm(M?2>+JS?Sovr1$4&o$%)J-Rvy1C(x_SP&_^+Q|ob2bvRapKnsB!uZWCC@52I{O^ z2-bM9wfSRp%D2x8&(zsXxp}_b==aZnXXVemp>9;U%XntjtvtiiA+LcRWbkzLb6Mw< G&;$U`n}MhR diff --git a/app/src/main/res/drawable/ic_expand_less.xml b/app/src/main/res/drawable/ic_expand_less.xml new file mode 100644 index 000000000..c1d4ac5bb --- /dev/null +++ b/app/src/main/res/drawable/ic_expand_less.xml @@ -0,0 +1,5 @@ + + + diff --git a/app/src/main/res/drawable/ic_expand_more.xml b/app/src/main/res/drawable/ic_expand_more.xml new file mode 100644 index 000000000..e6aa60301 --- /dev/null +++ b/app/src/main/res/drawable/ic_expand_more.xml @@ -0,0 +1,5 @@ + + + diff --git a/app/src/main/res/layout/app_details2_links.xml b/app/src/main/res/layout/app_details2_links.xml index 0eed84127..01263d8a6 100644 --- a/app/src/main/res/layout/app_details2_links.xml +++ b/app/src/main/res/layout/app_details2_links.xml @@ -27,8 +27,8 @@ android:paddingStart="@dimen/details_activity__collapsable_lists__padding__horizontal" android:paddingRight="@dimen/details_activity__collapsable_lists__padding__horizontal" android:paddingEnd="@dimen/details_activity__collapsable_lists__padding__horizontal" - android:drawableRight="@drawable/ic_expand_more_grey600" - android:drawableEnd="@drawable/ic_expand_more_grey600" + android:drawableRight="@drawable/ic_expand_more" + android:drawableEnd="@drawable/ic_expand_more" android:drawableLeft="@drawable/ic_website" android:drawableStart="@drawable/ic_website" android:background="?selectableItemBackground" /> diff --git a/app/src/main/res/layout/app_details2_version_item.xml b/app/src/main/res/layout/app_details2_version_item.xml index 452f8cd64..6c5619096 100644 --- a/app/src/main/res/layout/app_details2_version_item.xml +++ b/app/src/main/res/layout/app_details2_version_item.xml @@ -84,7 +84,7 @@ + android:src="@drawable/ic_expand_more" />