package com.unibuy.smartdevice.ui.dialog;

import android.content.Context;

import com.unibuy.smartdevice.DialogAbstract;
import com.unibuy.smartdevice.databinding.DialogSystemInspectionBinding;
import com.unibuy.smartdevice.tools.HandlerMain;
import com.unibuy.smartdevice.tools.ToastHandlerMain;

public class SystemInspectionDialog extends DialogAbstract {

    public SystemInspectionDialog(Context context, HandlerMain srcHandlerMain) {
        super(context, srcHandlerMain);
        getLogs().info("SystemInspectionDialog:" + getClass().getSimpleName());
    }

    @Override
    protected Context setCtx() {
        return this.getContext();
    }

    @Override
    protected Class<? extends DialogAbstract> setCls() {
        return getClass();
    }

    @Override
    protected HandlerMain setHandlerMain() {
        return new ToastHandlerMain(getContext(), getLogs()) {
            @Override
            protected void execute(Context context, int commandCode, String message) {
                super.execute(context, commandCode, message);
            }
        };
    }

    private DialogSystemInspectionBinding binding;

    @Override
    protected void onCreate(Context context) {
        binding = DialogSystemInspectionBinding.inflate(getLayoutInflater());
        setContentView(binding.getRoot());
    }
}
