Allow TabArchidekt to use VDE group/sort/display buttons

This commit is contained in:
Brübach, Lukas 2025-11-29 20:41:14 +01:00
parent b4d33597c2
commit 16350799bf
8 changed files with 253 additions and 136 deletions

View file

@ -74,6 +74,29 @@ enum Type
MANA_COST, /**< Group cards by their total mana cost. */
COLOR /**< Group cards by their color identity. */
};
static inline QString toString(Type t)
{
switch (t) {
case MAIN_TYPE:
return "Main Type";
case MANA_COST:
return "Mana Cost";
case COLOR:
return "Colors";
}
return {};
}
static inline Type fromString(const QString &s)
{
if (s == "Main Type")
return MAIN_TYPE;
if (s == "Mana Cost")
return MANA_COST;
if (s == "Colors")
return COLOR;
return MAIN_TYPE; // default
}
} // namespace DeckListModelGroupCriteria
/**