Commit 4da19e6e authored by wanglei's avatar wanglei

[添加]添加lottie依赖

parent 2475e1a9
...@@ -103,6 +103,8 @@ dependencies { ...@@ -103,6 +103,8 @@ dependencies {
//第三方UI控件 //第三方UI控件
implementation("io.github.cymchad:BaseRecyclerViewAdapterHelper4:4.1.4") implementation("io.github.cymchad:BaseRecyclerViewAdapterHelper4:4.1.4")
//lottie
implementation("com.airbnb.android:lottie:6.4.0")
//firebase //firebase
implementation(platform("com.google.firebase:firebase-bom:32.3.1")) implementation(platform("com.google.firebase:firebase-bom:32.3.1"))
......
...@@ -16,6 +16,7 @@ import com.applovin.mediation.nativeAds.MaxNativeAdViewBinder ...@@ -16,6 +16,7 @@ import com.applovin.mediation.nativeAds.MaxNativeAdViewBinder
import com.base.appzxhy.R import com.base.appzxhy.R
import com.google.android.gms.ads.nativead.NativeAd import com.google.android.gms.ads.nativead.NativeAd
import com.google.android.gms.ads.nativead.NativeAdView import com.google.android.gms.ads.nativead.NativeAdView
import androidx.core.content.withStyledAttributes
@SuppressLint("ViewConstructor") @SuppressLint("ViewConstructor")
class NativeParentView(context: Context, attrs: AttributeSet? = null) : class NativeParentView(context: Context, attrs: AttributeSet? = null) :
...@@ -25,20 +26,15 @@ class NativeParentView(context: Context, attrs: AttributeSet? = null) : ...@@ -25,20 +26,15 @@ class NativeParentView(context: Context, attrs: AttributeSet? = null) :
init { init {
// 获取XML属性 // 获取XML属性
val a = context.obtainStyledAttributes( context.withStyledAttributes(attrs, R.styleable.NativeParentView, 0, 0) {
attrs,
R.styleable.NativeParentView,
0,
0
)
// 从XML中读取属性值 // 从XML中读取属性值
// 例如,如果你的XML中有自定义属性 `app:customAttribute="value"` // 例如,如果你的XML中有自定义属性 `app:customAttribute="value"`
removeAll = a.getBoolean(R.styleable.NativeParentView_removeAll, true) removeAll = getBoolean(R.styleable.NativeParentView_removeAll, true)
// 回收TypedArray // 回收TypedArray
a.recycle() }
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment