3
* In the name of the Father, and of the Son, and of the Holy Spirit.
5
* This file is part of BibleTime's source code, http://www.bibletime.info/.
7
* Copyright 1999-2009 by the BibleTime developers.
8
* The BibleTime source code is licensed under the GNU General Public License
13
#ifndef BTMODULECATEGORYFILTERPROXYMODEL_H
14
#define BTMODULECATEGORYFILTERPROXYMODEL_H
16
#include <QSortFilterProxyModel>
18
#include "backend/drivers/cswordmoduleinfo.h"
21
class BtModuleCategoryFilterProxyModel: public QSortFilterProxyModel {
24
BtModuleCategoryFilterProxyModel(QObject *parent = 0);
25
virtual ~BtModuleCategoryFilterProxyModel();
27
inline bool enabled() const {
30
void setEnabled(bool enable);
32
inline CSwordModuleInfo::Categories shownCategories() const {
36
inline CSwordModuleInfo::Categories hiddenCategories() const {
37
return ~m_filter & CSwordModuleInfo::AllCategories;
39
void setShownCategories(CSwordModuleInfo::Categories cs);
40
void setHiddenCategories(CSwordModuleInfo::Categories cs);
42
virtual bool filterAcceptsRow(int row, const QModelIndex &parent) const;
45
CSwordModuleInfo::Categories m_filter;
49
#endif // BTMODULECATEGORYFILTERPROXYMODEL_H