Add options to include/exclude set name and collector number during clipboard import/export. (#5482)

* Add options to include/exclude set name and collector number during clipboard import/export.

* Missing parentheses in action label.

* Revert the silliest lint in the world.

---------

Co-authored-by: Lukas Brübach <Bruebach.Lukas@bdosecurity.de>
This commit is contained in:
BruebachL 2025-01-17 03:38:01 +01:00 committed by GitHub
parent 315c224f24
commit 80165c28a9
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
6 changed files with 108 additions and 17 deletions

View file

@ -45,6 +45,7 @@ public:
return lastRemoteDeckId;
}
void clearSetNamesAndNumbers();
static FileFormat getFormatFromName(const QString &fileName);
bool loadFromFile(const QString &fileName, FileFormat fmt, bool userRequest = false);
@ -57,15 +58,19 @@ public:
void resolveSetNameAndNumberToProviderID();
// overload
bool saveToStream_Plain(QTextStream &out, bool addComments = true);
bool saveToStream_Plain(QTextStream &out, bool addComments = true, bool addSetNameAndNumber = true);
protected:
void saveToStream_DeckHeader(QTextStream &out);
void saveToStream_DeckZone(QTextStream &out, const InnerDecklistNode *zoneNode, bool addComments = true);
void saveToStream_DeckZone(QTextStream &out,
const InnerDecklistNode *zoneNode,
bool addComments = true,
bool addSetNameAndNumber = true);
void saveToStream_DeckZoneCards(QTextStream &out,
const InnerDecklistNode *zoneNode,
QList<DecklistCardNode *> cards,
bool addComments = true);
bool addComments = true,
bool addSetNameAndNumber = true);
[[nodiscard]] QString getCardZoneFromName(QString cardName, QString currentZoneName) override;
[[nodiscard]] QString getCompleteCardName(const QString &cardName) const override;
};