- Added an option to toggle filtering lands by color identity on/off.

This commit is contained in:
Agetian
2015-06-08 13:00:14 +00:00
parent c6d7561e80
commit aa7adbda44
5 changed files with 24 additions and 2 deletions

View File

@@ -115,6 +115,8 @@ public enum CSubmenuPreferences implements ICDoc {
lstControls.add(Pair.of(view.getCbStackCreatures(), FPref.UI_STACK_CREATURES));
lstControls.add(Pair.of(view.getCbManaLostPrompt(), FPref.UI_MANA_LOST_PROMPT));
lstControls.add(Pair.of(view.getCbFilterLandsByColorId(), FPref.UI_FILTER_LANDS_BY_COLOR_IDENTITY));
for(final Pair<JCheckBox, FPref> kv : lstControls) {
kv.getKey().addItemListener(new ItemListener() {
@Override

View File

@@ -82,6 +82,7 @@ public enum VSubmenuPreferences implements IVSubmenu<CSubmenuPreferences> {
private final JCheckBox cbOpenPacksIndiv = new OptionsCheckBox("Open Packs Individually");
private final JCheckBox cbTokensInSeparateRow = new OptionsCheckBox("Display Tokens in a Separate Row");
private final JCheckBox cbStackCreatures = new OptionsCheckBox("Stack Creatures");
private final JCheckBox cbFilterLandsByColorId = new OptionsCheckBox("Filter Lands by Color Identity");
private final Map<FPref, KeyboardShortcutField> shortcutFields = new HashMap<>();
@@ -171,6 +172,12 @@ public enum VSubmenuPreferences implements IVSubmenu<CSubmenuPreferences> {
pnlPrefs.add(cbRemoveArtifacts, regularConstraints);
pnlPrefs.add(new NoteLabel("Disables artifact cards in generated decks."), regularConstraints);
// Deck building options
pnlPrefs.add(new SectionLabel("Deck Editor Options"), sectionConstraints);
pnlPrefs.add(cbFilterLandsByColorId, regularConstraints);
pnlPrefs.add(new NoteLabel("Filter lands by their color identity to make it easier to find relevant mana producing lands."), regularConstraints);
// Advanced
pnlPrefs.add(new SectionLabel("Advanced Settings"), sectionConstraints);
@@ -436,6 +443,11 @@ public enum VSubmenuPreferences implements IVSubmenu<CSubmenuPreferences> {
return cbRemoveArtifacts;
}
/** @return {@link javax.swing.JCheckBox} */
public JCheckBox getCbFilterLandsByColorId() {
return cbFilterLandsByColorId;
}
/** @return {@link javax.swing.JCheckBox} */
public JCheckBox getCbEnableAICheats() {
return cbEnableAICheats;