// Path: app/src/main/java/org/epstudios/epcoding/Constants.java
// public final static String EPCODING = "EPCODING";


import android.widget.Button;
import android.widget.CheckBox;
import android.widget.LinearLayout;
import java.util.HashSet;
import java.util.List;
import java.util.Set;
import static org.epstudios.epcoding.Constants.EPCODING;
import androidx.annotation.NonNull;
import android.app.Activity;
import android.content.Intent;
import android.content.SharedPreferences;
import android.os.Bundle;
import android.preference.PreferenceManager;
import android.util.Log;
import android.view.View;

        LinearLayout checkBoxLayout = findViewById(
                R.id.modifiers_checkbox_layout);


        code = Codes.getCode(codeNumber);
        modifierSet = code.getModifierSet();

        List<Modifier> allModifiers = Modifiers.allModifiersSorted();
        checkBoxes = new CheckBox[allModifiers.size()];
        createCheckBoxLayoutAndModifierMap(allModifiers, checkBoxLayout);

        if (savedInstanceState != null) {
            boolean[] checkBoxState = savedInstanceState.getBooleanArray("ModifierState");
            int i = 0;
            for (CheckBox checkBox : checkBoxes) {
                checkBox.setChecked(checkBoxState != null && checkBoxState[i++]);
            }
        }
        initToolbar();

        Button cancelButton = findViewById(R.id.cancel_button);
        cancelButton.setOnClickListener(this);
        Button resetButton = findViewById(R.id.reset_button);
        resetButton.setOnClickListener(this);
        Button saveButton = findViewById(R.id.save_button);
        saveButton.setOnClickListener(this);
        Button addButton = findViewById(R.id.add_button);
        addButton.setOnClickListener(this);

// Path: app/src/main/java/org/epstudios/epcoding/Constants.java
// public final static String EPCODING = "EPCODING";


// Path: app/src/main/java/org/epstudios/epcoding/ModifierActivity.java
import android.widget.Button;
import android.widget.CheckBox;
import android.widget.LinearLayout;
import java.util.HashSet;
import java.util.List;
import java.util.Set;
import static org.epstudios.epcoding.Constants.EPCODING;
import androidx.annotation.NonNull;
import android.app.Activity;
import android.content.Intent;
import android.content.SharedPreferences;
import android.os.Bundle;
import android.preference.PreferenceManager;
import android.util.Log;
import android.view.View;


        LinearLayout checkBoxLayout = findViewById(
                R.id.modifiers_checkbox_layout);


        code = Codes.getCode(codeNumber);
        modifierSet = code.getModifierSet();

        List<Modifier> allModifiers = Modifiers.allModifiersSorted();
        checkBoxes = new CheckBox[allModifiers.size()];
        createCheckBoxLayoutAndModifierMap(allModifiers, checkBoxLayout);

        if (savedInstanceState != null) {
            boolean[] checkBoxState = savedInstanceState.getBooleanArray("ModifierState");
            int i = 0;
            for (CheckBox checkBox : checkBoxes) {
                checkBox.setChecked(checkBoxState != null && checkBoxState[i++]);
            }
        }
        initToolbar();

        Button cancelButton = findViewById(R.id.cancel_button);
        cancelButton.setOnClickListener(this);
        Button resetButton = findViewById(R.id.reset_button);
        resetButton.setOnClickListener(this);
        Button saveButton = findViewById(R.id.save_button);
        saveButton.setOnClickListener(this);
        Button addButton = findViewById(R.id.add_button);
        addButton.setOnClickListener(this);

        Log.d(EPCODING, "onCreate");