servatrice/cockatrice/src/cardfilter.cpp
sylvanbasilisk 863e437d4c added filter builder widget and filter tree
filter builder takes filter options from user, then adds
completed filters to the filter tree. the filter tree does
not currently do anything. in the future it will filter the
cards in the database view.
2014-01-17 10:06:45 +00:00

31 lines
447 B
C++

#include "cardfilter.h"
const char *CardFilter::typeName(Type t)
{
switch(t) {
case TypeAnd:
return "and";
case TypeOr:
return "or";
case TypeAndNot:
return "and not";
case TypeOrNot:
return "or not";
default:
return "";
}
}
const char *CardFilter::attrName(Attr a)
{
switch(a) {
case AttrName:
return "name";
case AttrType:
return "type";
case AttrColor:
return "color";
default:
return "";
}
}