package com.youra.qlicker.Acitvitys.EspacePerso;
import com.youra.qlicker.R;

import androidx.appcompat.app.AppCompatActivity;

import android.content.Intent;
import android.os.Bundle;
import android.view.View;
import android.widget.CheckBox;
import android.widget.ImageView;
import android.widget.TextView;

public class EPgetEmailActivity extends AppCompatActivity {

    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_epget_email);

        TextView btn_next = (TextView) findViewById(R.id.btn_next);
        ImageView img_back = (ImageView) findViewById(R.id.img_back);
        CheckBox checkbox_accept = (CheckBox) findViewById(R.id.checkbox_accept);

        img_back.setOnClickListener(new View.OnClickListener() {
            @Override
            public void onClick(View v) {

                finish();

            }
        });

        btn_next.setOnClickListener(new View.OnClickListener() {
            @Override
            public void onClick(View v) {

                if(checkbox_accept.isChecked()){
                    startActivity(new Intent(EPgetEmailActivity.this, EPgetPhoneActivity.class ));
                }
                else {
                    startActivity(new Intent(EPgetEmailActivity.this, EPcheckEmailActivity.class ));
                }


            }
        });
    }
}