mirror of
https://github.com/Card-Forge/forge.git
synced 2025-11-17 19:28:01 +00:00
Prevent crash when activating card from zoom with multiple abilities
This commit is contained in:
@@ -181,7 +181,13 @@ public abstract class VCardDisplayArea extends VDisplayArea implements ActivateH
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void activate(int index) {
|
public void activate(int index) {
|
||||||
CardAreaPanel.get(orderedCards.get(index)).selectCard(false);
|
final CardAreaPanel cardPanel = CardAreaPanel.get(orderedCards.get(index));
|
||||||
|
ThreadUtil.invokeInGameThread(new Runnable() { //must invoke in game thread in case a dialog needs to be shown
|
||||||
|
@Override
|
||||||
|
public void run() {
|
||||||
|
cardPanel.selectCard(false);
|
||||||
|
}
|
||||||
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
public static class CardAreaPanel extends FCardPanel {
|
public static class CardAreaPanel extends FCardPanel {
|
||||||
|
|||||||
Reference in New Issue
Block a user