mirror of
https://github.com/Card-Forge/forge.git
synced 2025-11-16 18:58:00 +00:00
Merge branch 'assorted-fixes' into 'master'
Attempting to fix "Copy to Clipboard" not copying e.g. dual partner commanders. See merge request core-developers/forge!274
This commit is contained in:
@@ -184,23 +184,18 @@ public class FDeckViewer extends FDialog {
|
|||||||
}
|
}
|
||||||
deckList.append(s.toString()).append(": ");
|
deckList.append(s.toString()).append(": ");
|
||||||
sectionCards = new TreeMap<>();
|
sectionCards = new TreeMap<>();
|
||||||
if (s.isSingleCard()) {
|
deckList.append(nl);
|
||||||
deckList.append(cp.get(0).getName()).append(nl);
|
for (final Entry<PaperCard, Integer> ev : cp) {
|
||||||
|
cardName = ev.getKey().toString();
|
||||||
|
if (sectionCards.containsKey(cardName)) {
|
||||||
|
sectionCards.put(cardName, (int)sectionCards.get(cardName) + ev.getValue());
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
sectionCards.put(cardName, ev.getValue());
|
||||||
|
}
|
||||||
}
|
}
|
||||||
else {
|
for (final Entry<String, Integer> ev: sectionCards.entrySet()) {
|
||||||
deckList.append(nl);
|
deckList.append(ev.getValue()).append(" ").append(ev.getKey()).append(nl);
|
||||||
for (final Entry<PaperCard, Integer> ev : cp) {
|
|
||||||
cardName = ev.getKey().toString();
|
|
||||||
if (sectionCards.containsKey(cardName)) {
|
|
||||||
sectionCards.put(cardName, (int)sectionCards.get(cardName) + ev.getValue());
|
|
||||||
}
|
|
||||||
else {
|
|
||||||
sectionCards.put(cardName, ev.getValue());
|
|
||||||
}
|
|
||||||
}
|
|
||||||
for (final Entry<String, Integer> ev: sectionCards.entrySet()) {
|
|
||||||
deckList.append(ev.getValue()).append(" ").append(ev.getKey()).append(nl);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
deckList.append(nl);
|
deckList.append(nl);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -93,14 +93,9 @@ public class FDeckViewer extends FScreen {
|
|||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
deckList.append(s.toString()).append(": ");
|
deckList.append(s.toString()).append(": ");
|
||||||
if (s.isSingleCard()) {
|
deckList.append(nl);
|
||||||
deckList.append(cp.get(0).getName()).append(nl);
|
for (final Entry<PaperCard, Integer> ev : cp) {
|
||||||
}
|
deckList.append(ev.getValue()).append(" ").append(ev.getKey()).append(nl);
|
||||||
else {
|
|
||||||
deckList.append(nl);
|
|
||||||
for (final Entry<PaperCard, Integer> ev : cp) {
|
|
||||||
deckList.append(ev.getValue()).append(" ").append(ev.getKey()).append(nl);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
deckList.append(nl);
|
deckList.append(nl);
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user