Fix Card Reveal Animation for default display

This commit is contained in:
Anthony Calosa
2020-03-02 12:30:02 +08:00
parent cb1b8024b4
commit f654982e38

View File

@@ -244,10 +244,7 @@ public class ConquestRewardDialog extends FScrollPane {
//ensure current card in view //ensure current card in view
if (getScrollHeight() > getHeight() && index < cardCount) { if (getScrollHeight() > getHeight() && index < cardCount) {
CardRevealer currentCard = cardRevealers.get(index); CardRevealer currentCard = cardRevealers.get(index);
if (!Forge.extrawide.equals("default")) scrollIntoView(currentCard, currentCard.getHeight() / (columnCount * PADDING) / 2);
scrollIntoView(currentCard, currentCard.getHeight() / (columnCount * PADDING) / 2);
else
scrollIntoView(currentCard, currentCard.getHeight() / 2 + PADDING); //show half of the card below
} }
} }