mirror of
https://github.com/Card-Forge/forge.git
synced 2025-11-17 11:18:01 +00:00
Merge branch 'master' into 'master'
cleanup See merge request core-developers/forge!4379
This commit is contained in:
@@ -215,7 +215,7 @@ public class GuiMobile implements IGuiBase {
|
|||||||
public void showCardList(final String title, final String message, final List<PaperCard> list) {
|
public void showCardList(final String title, final String message, final List<PaperCard> list) {
|
||||||
final Deck deck = new Deck(title + " - " + message);
|
final Deck deck = new Deck(title + " - " + message);
|
||||||
deck.getMain().addAllFlat(list);
|
deck.getMain().addAllFlat(list);
|
||||||
FDeckViewer.show(deck, true); //TODO: limit this to Android only?
|
FDeckViewer.show(deck, true);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
|||||||
@@ -73,7 +73,6 @@ public class ImageCache {
|
|||||||
private static final LoadingCache<String, Texture> cache = CacheBuilder.newBuilder()
|
private static final LoadingCache<String, Texture> cache = CacheBuilder.newBuilder()
|
||||||
.maximumSize(Forge.cacheSize)
|
.maximumSize(Forge.cacheSize)
|
||||||
.expireAfterAccess(15, TimeUnit.MINUTES)
|
.expireAfterAccess(15, TimeUnit.MINUTES)
|
||||||
.softValues()
|
|
||||||
.removalListener(new RemovalListener<String, Texture>() {
|
.removalListener(new RemovalListener<String, Texture>() {
|
||||||
@Override
|
@Override
|
||||||
public void onRemoval(RemovalNotification<String, Texture> removalNotification) {
|
public void onRemoval(RemovalNotification<String, Texture> removalNotification) {
|
||||||
|
|||||||
@@ -116,13 +116,10 @@ public class FDeckViewer extends FScreen {
|
|||||||
public static void show(final Deck deck0) {
|
public static void show(final Deck deck0) {
|
||||||
show(deck0, false);
|
show(deck0, false);
|
||||||
}
|
}
|
||||||
public static void show(final Deck deck0, boolean disposeTexture) {
|
public static void show(final Deck deck0, boolean noPreload) {
|
||||||
if (deck0 == null) { return; }
|
if (deck0 == null) { return; }
|
||||||
|
|
||||||
if (disposeTexture) {
|
if (!noPreload){
|
||||||
/*this is called on Quest shoplist, quest rewards, quest unlock sets*/
|
|
||||||
ImageCache.disposeTexture();
|
|
||||||
} else {
|
|
||||||
/*preload deck to cache*/
|
/*preload deck to cache*/
|
||||||
ImageCache.preloadCache(deck0);
|
ImageCache.preloadCache(deck0);
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user