From 58037db8fbfe47d5847cbe39fee1ff4694ec9bb4 Mon Sep 17 00:00:00 2001 From: Gary Mathews Date: Thu, 28 Oct 2021 10:09:05 -0700 Subject: [PATCH] fix(android): amend ShapeDrawable workaround --- .../titanium/ui/widget/listview/TiRecyclerViewHolder.java | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/android/modules/ui/src/java/ti/modules/titanium/ui/widget/listview/TiRecyclerViewHolder.java b/android/modules/ui/src/java/ti/modules/titanium/ui/widget/listview/TiRecyclerViewHolder.java index a689ce04e5e..5084441a171 100644 --- a/android/modules/ui/src/java/ti/modules/titanium/ui/widget/listview/TiRecyclerViewHolder.java +++ b/android/modules/ui/src/java/ti/modules/titanium/ui/widget/listview/TiRecyclerViewHolder.java @@ -203,9 +203,9 @@ protected Drawable generateSelectedDrawable(KrollDict properties, Drawable drawa stateDrawable.addState(new int[] { android.R.attr.state_activated }, new ColorDrawable(COLOR_SELECTED)); } - // NOTE: Android 6.0 and below require ShapeDrawable to have non-null Shape. - // This bug is fixed on Android 7.0 and above. - if (Build.VERSION.SDK_INT < Build.VERSION_CODES.N) { + // NOTE: Android 7.1 and below require ShapeDrawable to have non-null Shape. + // This bug is fixed on Android 8.0 and above. + if (Build.VERSION.SDK_INT < Build.VERSION_CODES.O) { Drawable currentDrawable = drawable; if (currentDrawable instanceof RippleDrawable) {