Closed Redman1037 closed 6 years ago
The Issue is caused at the line 121 in RecordView ,don't know reason
animatedVectorDrawable = AnimatedVectorDrawableCompat.create(context, R.drawable.basket_animated);
so I added a version check before its usages
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.LOLLIPOP)
animatedVectorDrawable = AnimatedVectorDrawableCompat.create(context, R.drawable.basket_animated);
in animateBasketMethod
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.LOLLIPOP)
basketImg.setImageDrawable(animatedVectorDrawable);
else
basketImg.setImageResource(R.drawable.ic_delete);
in OnAnimationEnd
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.LOLLIPOP)
animatedVectorDrawable.start();
@Redman1037 can you please provide the XML ?
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="@color/backGround"
android:orientation="vertical">
<include layout="@layout/default_toolbar" />
<in.eightfolds.soundvision.utils.MyTextViewCenturyGothic
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="Mp3 files"
style="@style/tvIntermediateHeading"/>
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:tools="http://schemas.android.com/tools"
android:id="@+id/parent_layout"
android:layout_width="match_parent"
android:layout_height="match_parent"
tools:context="com.devlomi.recordview.MainActivity">
<android.support.v7.widget.RecyclerView
android:id="@+id/recyclerview_songsList"
android:layout_width="match_parent"
android:layout_height="match_parent">
</android.support.v7.widget.RecyclerView>
<RelativeLayout
android:id="@+id/relative_mic"
android:layout_width="match_parent"
android:layout_height="100dp"
android:layout_alignParentBottom="true"
android:layout_alignParentLeft="true"
android:layout_alignParentStart="true">
<com.devlomi.record_view.RecordView
android:id="@+id/record_view"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_alignParentBottom="true"
android:layout_marginBottom="15dp"
android:layout_toLeftOf="@id/record_button"
app:slide_to_cancel_arrow="@drawable/ic_keyboard_arrow_left"
app:slide_to_cancel_margin_right="15dp"
app:slide_to_cancel_text="Slide To Cancel" />
<com.devlomi.record_view.RecordButton
android:id="@+id/record_button"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignParentBottom="true"
android:layout_alignParentRight="true"
android:layout_marginBottom="15dp"
android:layout_marginRight="5dp"
android:background="@drawable/mic_bg"
android:padding="20dp"
android:scaleType="centerInside"
app:src="@drawable/ic_mic_white" />
</RelativeLayout>
</RelativeLayout>
</LinearLayout>
Hey @Redman1037 the problem is because you have the Drawable with the name ic_delete which is the same name of the Vector Drawable that included in the Library. you can just rename the the drawable ic_delete that you have to another name ,until i push the new Update and change the name of it.
please try it and report back.
A new update has been published with fixes for the drawables names issues
Device :- Samsung galaxy Note 2 Version:- Android 4.4.2
Crash Log