package com.quyunshuo.module.home.dialog

import android.content.Context
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.OpenOrCloseDialogBinding


/**
 * 报警 对话框
 */
class OpenOrCloseDialog(mContext: Context) : BaseFrameDialog<OpenOrCloseDialogBinding>(mContext),
    LifecycleObserver {

    var type1: Int = 1
    var type2: Int = 2


    private var devOnoffDialoglistener: DialogClickListener? = null

    override fun OpenOrCloseDialogBinding.initView() {

    }

    @OnLifecycleEvent(Lifecycle.Event.ON_STOP)
    override fun dismiss() {
        super.dismiss()
    }

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


    override fun initObserve() {
    }

    override fun initRequestData() {
    }

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

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


}