mirror of
https://github.com/Card-Forge/forge.git
synced 2025-11-19 04:08:01 +00:00
Don't filter out multicolor cards after right-clicking a color filter
This commit is contained in:
@@ -116,6 +116,7 @@ public enum CCardCatalog implements ICDoc {
|
|||||||
final int group = st.group;
|
final int group = st.group;
|
||||||
if (group > 0) {
|
if (group > 0) {
|
||||||
statLabel.setRightClickCommand(new Command() {
|
statLabel.setRightClickCommand(new Command() {
|
||||||
|
@SuppressWarnings("incomplete-switch")
|
||||||
@Override
|
@Override
|
||||||
public void run() {
|
public void run() {
|
||||||
if (!disableFiltering) {
|
if (!disableFiltering) {
|
||||||
@@ -126,6 +127,16 @@ public enum CCardCatalog implements ICDoc {
|
|||||||
if (s.group == group && s != st) {
|
if (s.group == group && s != st) {
|
||||||
FLabel lbl = VCardCatalog.SINGLETON_INSTANCE.getItemManager().getStatLabel(s);
|
FLabel lbl = VCardCatalog.SINGLETON_INSTANCE.getItemManager().getStatLabel(s);
|
||||||
if (lbl.getSelected()) {
|
if (lbl.getSelected()) {
|
||||||
|
if (s == StatTypes.MULTICOLOR) {
|
||||||
|
switch (st) {
|
||||||
|
case WHITE:
|
||||||
|
case BLUE:
|
||||||
|
case BLACK:
|
||||||
|
case RED:
|
||||||
|
case GREEN:
|
||||||
|
continue; //don't filter out multicolor cards after right-clicking a color filter
|
||||||
|
}
|
||||||
|
}
|
||||||
foundSelected = true;
|
foundSelected = true;
|
||||||
lbl.setSelected(false);
|
lbl.setSelected(false);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -104,6 +104,7 @@ public enum CWorkshopCatalog implements ICDoc {
|
|||||||
final int group = st.group;
|
final int group = st.group;
|
||||||
if (group > 0) {
|
if (group > 0) {
|
||||||
statLabel.setRightClickCommand(new Command() {
|
statLabel.setRightClickCommand(new Command() {
|
||||||
|
@SuppressWarnings("incomplete-switch")
|
||||||
@Override
|
@Override
|
||||||
public void run() {
|
public void run() {
|
||||||
if (!disableFiltering) {
|
if (!disableFiltering) {
|
||||||
@@ -114,6 +115,16 @@ public enum CWorkshopCatalog implements ICDoc {
|
|||||||
if (s.group == group && s != st) {
|
if (s.group == group && s != st) {
|
||||||
FLabel lbl = VWorkshopCatalog.SINGLETON_INSTANCE.getCardManager().getStatLabel(s);
|
FLabel lbl = VWorkshopCatalog.SINGLETON_INSTANCE.getCardManager().getStatLabel(s);
|
||||||
if (lbl.getSelected()) {
|
if (lbl.getSelected()) {
|
||||||
|
if (s == StatTypes.MULTICOLOR) {
|
||||||
|
switch (st) {
|
||||||
|
case WHITE:
|
||||||
|
case BLUE:
|
||||||
|
case BLACK:
|
||||||
|
case RED:
|
||||||
|
case GREEN:
|
||||||
|
continue; //don't filter out multicolor cards after right-clicking a color filter
|
||||||
|
}
|
||||||
|
}
|
||||||
foundSelected = true;
|
foundSelected = true;
|
||||||
lbl.setSelected(false);
|
lbl.setSelected(false);
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user