Update and cleanup card viewing code. Fixes issue with

morph colour leaking, viewing opponent's morphs through
card zoomer, and other minor bugs.
This commit is contained in:
elcnesh
2015-05-18 07:33:21 +00:00
parent 5cba52b5a6
commit 9767b20386
14 changed files with 149 additions and 154 deletions

View File

@@ -153,6 +153,21 @@ public class CardDetailUtil {
return borderColors;
}
public static DetailColors getRarityColor(final CardRarity rarity) {
switch (rarity) {
case Uncommon:
return DetailColors.UNCOMMON;
case Rare:
return DetailColors.RARE;
case MythicRare:
return DetailColors.MYTHIC;
case Special: //"Timeshifted" or other Special Rarity Cards
return DetailColors.SPECIAL;
default: //case BasicLand: + case Common:
return DetailColors.COMMON;
}
}
public static String getItemDescription(final InventoryItemFromSet item) {
if (item instanceof SealedProduct) {
return ((SealedProduct)item).getDescription();