package com.example.defenseapplication.login

import android.content.Intent
import android.os.Bundle
import android.widget.Toast
import androidx.activity.enableEdgeToEdge
import androidx.appcompat.app.AppCompatActivity
import androidx.core.view.ViewCompat
import androidx.core.view.WindowInsetsCompat
import com.example.defenseapplication.R
import com.example.defenseapplication.databinding.FaceLoginActivityBinding
import com.gyf.immersionbar.ImmersionBar
//人脸识别
class FaceLoginActivity : AppCompatActivity() {

    private lateinit var binding: FaceLoginActivityBinding
    override fun onCreate(savedInstanceState: Bundle?) {
        super.onCreate(savedInstanceState)
        binding = FaceLoginActivityBinding.inflate(layoutInflater)
        setContentView(binding.root)
        ImmersionBar.with(this)
            .statusBarDarkFont(true)
            .titleBar(binding.topContainer)
            .init()
        setupListeners()
    }

    private fun setupListeners() {
        // 返回按钮
        binding.backIcon.setOnClickListener {
            finish()
        }

        // 继续按钮
        binding.btnStartVerification.setOnClickListener {
            val intent= Intent(this, FaceVerificationActivity::class.java)
            startActivity(intent)
            Toast.makeText(this, R.string.redirect_face_recognition_page, Toast.LENGTH_SHORT).show()


        }
    }
}