package com.adealink.weparty.room.micseat.defaults

import android.content.Context
import android.util.AttributeSet
import androidx.annotation.CallSuper
import com.adealink.weparty.room.micseat.DecorDynamicLayers
import com.adealink.weparty.room.micseat.decor.AvatarDecorView
import com.adealink.weparty.room.micseat.decor.AvatarFrameDecorView
import com.adealink.weparty.room.micseat.decor.MuteDecorView
import com.adealink.weparty.room.micseat.decor.SpeakingRippleDecorView

abstract class DefaultSeatView @JvmOverloads constructor(
    context: Context,
    attrs: AttributeSet? = null,
    defStyleAttr: Int = 0,
) : BaseDefaultSeatView(context, attrs, defStyleAttr) {

    override fun initDecorLayers(): DecorDynamicLayers {
        return DecorDynamicLayers(this, MIC_SEAT_DECOR_HIERARCHY)
    }

    @CallSuper
    override fun initViews() {
        addDecorView(AvatarFrameDecorView(dynamicLayers))
        addDecorView(MuteDecorView(dynamicLayers))
        addDecorView(SpeakingRippleDecorView(dynamicLayers))
    }

}