package com.xty.common.app

import android.os.Bundle
import androidx.appcompat.app.AppCompatActivity
import cat.ereza.customactivityoncrash.CustomActivityOnCrash
import com.xty.common.databinding.ActCrashBinding

class CrashAct: AppCompatActivity() {
    val binding by lazy{ ActCrashBinding.inflate(layoutInflater)}
    override fun onCreate(savedInstanceState: Bundle?) {
        super.onCreate(savedInstanceState)
        setContentView(binding.root)
        binding.mResert.setOnClickListener {
            var config=  CustomActivityOnCrash.getConfigFromIntent(intent);
            CustomActivityOnCrash.restartApplication(this, config!!)
        }
        binding.mClose.setOnClickListener {
            finish()
        }
    }
}