| 60 | } |
| 61 | |
| 62 | bool QmitkDataStorageFilterProxyModel::filterAcceptsRow(int sourceRow, const QModelIndex &sourceParent) const |
| 63 | { |
| 64 | QmitkDataStorageTreeModel *model = dynamic_cast<QmitkDataStorageTreeModel *>(this->sourceModel()); |
| 65 | assert(model); |
| 66 | |
| 67 | QModelIndex index0 = sourceModel()->index(sourceRow, 0, sourceParent); |
| 68 | |
| 69 | for (FilterPredicatesCollection::const_iterator iter = m_Predicates.begin(); iter != m_Predicates.end(); ++iter) |
| 70 | { |
| 71 | if ((*iter)->CheckNode(model->GetNode(index0))) |
| 72 | { |
| 73 | return false; |
| 74 | } |
| 75 | } |
| 76 | |
| 77 | return true; |
| 78 | } |