package com.adealink.weparty.commonui.widget

import android.content.Context
import android.util.AttributeSet
import android.view.LayoutInflater
import androidx.constraintlayout.widget.ConstraintLayout
import com.adealink.weparty.databinding.LayoutCollectCoinViewBinding

/**
 * 收集路径动效
 * 支持多条路径
 */
class CollectCoinView @JvmOverloads constructor(
    context: Context, attrs: AttributeSet? = null
) : ConstraintLayout(context, attrs) {

    private val binding = LayoutCollectCoinViewBinding.inflate(LayoutInflater.from(context), this)

    private var showFlashAnim = false

    fun showFlashAnim() {
        if (showFlashAnim) {
            return
        }
        showFlashAnim = true
//        binding.ivBg.show()
//        binding.ivBg.startAnimation(
//            ScaleAnimation(
//                0.3f, 1f,
//                0.3f, 1f,
//                Animation.RELATIVE_TO_SELF, 0.5f,
//                Animation.RELATIVE_TO_SELF, 0.5f
//            ).apply {
//                duration = 50
//            }
//        )
    }
}