Adding Set Code To Filtering Method

Updating Tab To Include Set Param
This commit is contained in:
Phoenix Osiris 2013-07-17 17:21:00 -04:00
parent 4f61da62e8
commit 2e1f5332db
4 changed files with 21 additions and 2 deletions

View file

@ -144,6 +144,19 @@ bool CardDatabaseDisplayModel::filterAcceptsRow(int sourceRow, const QModelIndex
if (!cardTypes.contains(info->getMainCardType()))
return false;
if (!cardSet.isEmpty()) {
bool blnGood = false;
for(int intLoop = 0; intLoop < info->getSets().count(); intLoop++) {
if (info->getSets().at(intLoop)->getShortName() == cardSet) {
blnGood = true;
break;
}
}
if (!blnGood) {
return false;
}
}
return true;
}