mirror of
https://github.com/correl/mage.git
synced 2024-11-25 03:00:11 +00:00
* Images: fixed wrong token filter and stats in images download dialog (#8443);
This commit is contained in:
parent
697beedb7d
commit
903a9215cc
1 changed files with 7 additions and 2 deletions
|
@ -314,6 +314,7 @@ public class DownloadPicturesService extends DefaultBoundedRangeModel implements
|
||||||
private void reloadCardsToDownload(String selectedItem) {
|
private void reloadCardsToDownload(String selectedItem) {
|
||||||
// find selected sets
|
// find selected sets
|
||||||
selectedSets.clear();
|
selectedSets.clear();
|
||||||
|
boolean onlyTokens = false;
|
||||||
List<String> formatSets;
|
List<String> formatSets;
|
||||||
List<String> sourceSets = selectedSource.getSupportedSets();
|
List<String> sourceSets = selectedSource.getSupportedSets();
|
||||||
switch (selectedItem) {
|
switch (selectedItem) {
|
||||||
|
@ -337,6 +338,8 @@ public class DownloadPicturesService extends DefaultBoundedRangeModel implements
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case ALL_TOKENS:
|
case ALL_TOKENS:
|
||||||
|
selectedSets.addAll(selectedSource.getSupportedSets());
|
||||||
|
onlyTokens = true;
|
||||||
break;
|
break;
|
||||||
|
|
||||||
default:
|
default:
|
||||||
|
@ -355,12 +358,14 @@ public class DownloadPicturesService extends DefaultBoundedRangeModel implements
|
||||||
for (CardDownloadData data : cardsMissing) {
|
for (CardDownloadData data : cardsMissing) {
|
||||||
if (data.isToken()) {
|
if (data.isToken()) {
|
||||||
if (selectedSource.isTokenSource()
|
if (selectedSource.isTokenSource()
|
||||||
&& selectedSource.isTokenImageProvided(data.getSet(), data.getName(), data.getType())) {
|
&& selectedSource.isTokenImageProvided(data.getSet(), data.getName(), data.getType())
|
||||||
|
&& selectedSets.contains(data.getSet())) {
|
||||||
numberTokenImagesAvailable++;
|
numberTokenImagesAvailable++;
|
||||||
cardsDownloadQueue.add(data);
|
cardsDownloadQueue.add(data);
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
if (selectedSource.isCardSource()
|
if (!onlyTokens
|
||||||
|
&& selectedSource.isCardSource()
|
||||||
&& selectedSource.isCardImageProvided(data.getSet(), data.getName())
|
&& selectedSource.isCardImageProvided(data.getSet(), data.getName())
|
||||||
&& selectedSets.contains(data.getSet())) {
|
&& selectedSets.contains(data.getSet())) {
|
||||||
numberCardImagesAvailable++;
|
numberCardImagesAvailable++;
|
||||||
|
|
Loading…
Reference in a new issue