Multiple bg images zone (#4005)

This commit is contained in:
fdipilla 2020-08-23 16:55:53 -03:00 committed by GitHub
parent 964207d04f
commit b0c7b9078d
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
6 changed files with 68 additions and 9 deletions

View file

@ -9,6 +9,7 @@
#include <QString>
typedef QMap<QString, QString> QStringMap;
typedef QMap<int, QBrush> QBrushMap;
class QApplication;
@ -21,10 +22,15 @@ public:
private:
QBrush handBgBrush, stackBgBrush, tableBgBrush, playerBgBrush;
QStringMap availableThemes;
/*
Internal cache for table backgrounds
*/
QBrushMap tableBgBrushesCache;
protected:
void ensureThemeDirectoryExists();
QBrush loadBrush(QString fileName, QColor fallbackColor);
QBrush loadExtraBrush(QString fileName, QBrush &fallbackBrush);
public:
QBrush &getHandBgBrush()
@ -44,7 +50,7 @@ public:
return playerBgBrush;
}
QStringMap &getAvailableThemes();
QBrush getExtraTableBgBrush(QString extraNumber);
QBrush getExtraTableBgBrush(QString extraNumber, QBrush &fallbackBrush);
protected slots:
void themeChangedSlot();
signals: