mirror of
https://github.com/correl/mage.git
synced 2025-01-12 19:25:44 +00:00
Fix cards still not showing selectable highlight in some cases
* Simply invalidating the image render is not enough, a repaint call is also needed in a few cases where a repaint hadn't already been scheduled by the same change that trigged the selectable/chosen status change.
This commit is contained in:
parent
274bdfa33f
commit
28c04e2009
1 changed files with 4 additions and 2 deletions
|
@ -398,8 +398,9 @@ public class CardPanelRenderImpl extends CardPanel {
|
|||
public void setSelected(boolean selected) {
|
||||
if (selected != isSelected()) {
|
||||
super.setSelected(selected);
|
||||
// Invalidate our render
|
||||
// Invalidate our render and trigger a repaint
|
||||
cardImage = null;
|
||||
repaint();
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -407,8 +408,9 @@ public class CardPanelRenderImpl extends CardPanel {
|
|||
public void setChoosable(boolean choosable) {
|
||||
if (choosable != isChoosable()) {
|
||||
super.setChoosable(choosable);
|
||||
// Invalidate our render
|
||||
// Invalidate our render and trigger a repaint
|
||||
cardImage = null;
|
||||
repaint();
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue