mirror of
https://github.com/Card-Forge/forge.git
synced 2025-11-16 10:48:00 +00:00
- Less aggressive match UI repaint on removeCardPanel (since it's done for the sake of targeting overlay, only call repaint for the selected card panel).
This commit is contained in:
@@ -292,13 +292,19 @@ public abstract class CardPanelContainer extends SkinnedPanel {
|
||||
remove(CardPanel.getDragAnimationPanel());
|
||||
setMouseDragPanel(null);
|
||||
}
|
||||
|
||||
boolean selected = fromPanel != null && fromPanel.isSelected();
|
||||
|
||||
hoveredPanel = null;
|
||||
fromPanel.dispose();
|
||||
getCardPanels().remove(fromPanel);
|
||||
remove(fromPanel);
|
||||
invalidate();
|
||||
repaint();
|
||||
FView.SINGLETON_INSTANCE.getFrame().repaint(); // necessary to get rid of lingering visual artifacts (e.g. unneeded targeting arrows)
|
||||
|
||||
if (selected) {
|
||||
FView.SINGLETON_INSTANCE.getFrame().repaint(); // necessary to get rid of lingering visual artifacts (e.g. unneeded targeting arrows)
|
||||
}
|
||||
}
|
||||
|
||||
public final void setCardPanels(final List<CardPanel> cardPanels) {
|
||||
|
||||
Reference in New Issue
Block a user