* Add MagicCards.info like fitler parser. * Use FilterString whenever one of [:=<>] is in the edit box. * Opts * Opt * - Capture errors - Allow querying any property by full name * clang format * Update cockatrice/src/filter_string.cpp Co-Authored-By: basicer <basicer@basicer.com> * - Some refactoring for clarity - More filters - Add filter help * Clangify * Add icon * Fix test name * Remove stay debug * - Add Rarity filter - Make " trigger filter string mode * You have to pass both filter types * clangify * - Allow filtering by legality - Import legality into card.xml * Add format filter to filtertree * More color search options * RIP extended * More fixes * Fix c:m * set syntax help parent * Fix warning * add additional explanations to syntax help * Allow multiple ands/ors to be chained * Cleanup and refactor Signed-off-by: Zach Halpern <ZaHalpern+github@gmail.com> * Move utility into guards Signed-off-by: Zach Halpern <ZaHalpern+github@gmail.com> * I heard you like refactors so I put a refactor inside your refactor (#3594) * I heard you like refactors so I put a refactor inside your refactor so you can refactor while you refactor * clangify * Update tab_deck_editor.h
51 lines
1.1 KiB
C++
51 lines
1.1 KiB
C++
/*
|
|
* Beware of this preprocessor hack used to redefine the settingCache class
|
|
* instead of including it and all of its dependencies.
|
|
*/
|
|
|
|
#include <QObject>
|
|
#include <QString>
|
|
|
|
#include "../../cockatrice/src/carddatabase.h"
|
|
|
|
#define SETTINGSCACHE_H
|
|
|
|
|
|
class CardDatabaseSettings
|
|
{
|
|
public:
|
|
void setSortKey(QString shortName, unsigned int sortKey);
|
|
void setEnabled(QString shortName, bool enabled);
|
|
void setIsKnown(QString shortName, bool isknown);
|
|
|
|
unsigned int getSortKey(QString shortName);
|
|
bool isEnabled(QString shortName);
|
|
bool isKnown(QString shortName);
|
|
};
|
|
|
|
class SettingsCache : public QObject
|
|
{
|
|
Q_OBJECT
|
|
private:
|
|
CardDatabaseSettings *cardDatabaseSettings;
|
|
|
|
public:
|
|
SettingsCache();
|
|
~SettingsCache();
|
|
QString getCustomCardDatabasePath() const;
|
|
QString getCardDatabasePath() const;
|
|
QString getTokenDatabasePath() const;
|
|
QString getSpoilerCardDatabasePath() const;
|
|
CardDatabaseSettings &cardDatabase() const;
|
|
signals:
|
|
void cardDatabasePathChanged();
|
|
};
|
|
|
|
extern SettingsCache *settingsCache;
|
|
|
|
#define PICTURELOADER_H
|
|
|
|
class PictureLoader
|
|
{
|
|
void clearPixmapCache(CardInfoPtr card);
|
|
};
|