package com.quyunshuo.module.home.dialog

import android.content.Context
import android.util.Log
import androidx.lifecycle.Lifecycle
import androidx.lifecycle.LifecycleObserver
import androidx.lifecycle.OnLifecycleEvent
import com.hboxs.serialport.plc.DialogClickListener
import com.quyunshuo.androidbaseframemvvm.base.mvvm.v.BaseFrameDialog
import com.quyunshuo.module.home.databinding.BackstageDialogPaySuccessBinding

/**
 * 支付成功对话框
 */
class PaySuccessDialog(mContext: Context) : BaseFrameDialog<BackstageDialogPaySuccessBinding>(mContext),
    LifecycleObserver {

    var type1:Int =1
    var type2:Int =2
    private val TAG = "PaySuccessDialog"

    private var devOnoffDialoglistener: DialogClickListener? = null

    override fun BackstageDialogPaySuccessBinding.initView() {
    }

    @OnLifecycleEvent(Lifecycle.Event.ON_STOP)
    override fun dismiss() {
        Log.d(TAG, "dismiss: ")
        super.dismiss()
    }

    override fun createVB() = BackstageDialogPaySuccessBinding.inflate(layoutInflater)


    override fun initObserve() {
    }

    override fun initRequestData() {
    }

    fun setListener(listener: DialogClickListener) {
        this.devOnoffDialoglistener = listener
    }

    fun setContent(content: String) {
        mBinding.tvTitle.text = content
    }


}