mirror of
https://github.com/correl/mage.git
synced 2024-12-25 03:00:15 +00:00
added swallowing the exception occurred time to time on battlefield permanent sort
This commit is contained in:
parent
b4e3e07274
commit
a260fd92b2
1 changed files with 7 additions and 1 deletions
|
@ -256,7 +256,13 @@ public class CardPluginImpl implements CardPlugin {
|
||||||
int panelX = x + (stackPosition * stackSpacingX);
|
int panelX = x + (stackPosition * stackSpacingX);
|
||||||
int panelY = y + (stackPosition * stackSpacingY);
|
int panelY = y + (stackPosition * stackSpacingY);
|
||||||
//panel.setLocation(panelX, panelY);
|
//panel.setLocation(panelX, panelY);
|
||||||
|
try {
|
||||||
|
// may cause:
|
||||||
|
// java.lang.IllegalArgumentException: illegal component position 26 should be less then 26
|
||||||
battlefieldPanel.moveToBack(panel);
|
battlefieldPanel.moveToBack(panel);
|
||||||
|
} catch (Exception e) {
|
||||||
|
e.printStackTrace();
|
||||||
|
}
|
||||||
panel.setCardBounds(panelX, panelY, cardWidth, cardHeight);
|
panel.setCardBounds(panelX, panelY, cardWidth, cardHeight);
|
||||||
}
|
}
|
||||||
rowBottom = Math.max(rowBottom, y + stack.getHeight());
|
rowBottom = Math.max(rowBottom, y + stack.getHeight());
|
||||||
|
|
Loading…
Reference in a new issue