KDEUI
kcheckableproxymodel.cpp
Go to the documentation of this file.
61 connect(itemSelectionModel, SIGNAL(selectionChanged(QItemSelection,QItemSelection)), SLOT(selectionChanged(QItemSelection,QItemSelection)));
88 return d->m_itemSelectionModel->selection().contains(mapToSource(index)) ? Qt::Checked : Qt::Unchecked;
105 bool result = select(QItemSelection(srcIndex, srcIndex), state == Qt::Checked ? QItemSelectionModel::Select : QItemSelectionModel::Deselect);
115 Q_ASSERT(d_ptr->m_itemSelectionModel ? d_ptr->m_itemSelectionModel->model() == sourceModel : true);
118 void KCheckableProxyModelPrivate::selectionChanged(const QItemSelection &selected, const QItemSelection &deselected)
127 bool KCheckableProxyModel::select(const QItemSelection& selection, QItemSelectionModel::SelectionFlags command)
bool setData(const QModelIndex &index, const QVariant &value, int role=Qt::EditRole)
Definition: kcheckableproxymodel.cpp:93
The KIdentityProxyModel class proxies its source model unmodified.
Definition: kidentityproxymodel.h:31
Adds a checkable capability to a source model.
Definition: kcheckableproxymodel.h:68
QVariant data(const QModelIndex &index, int role=Qt::DisplayRole) const
Definition: kcheckableproxymodel.cpp:77
QItemSelectionModel * selectionModel() const
Definition: kcheckableproxymodel.cpp:64
KCheckableProxyModel(QObject *parent=0)
Definition: kcheckableproxymodel.cpp:45
Definition: kstandardaction.h:133
~KCheckableProxyModel()
Definition: kcheckableproxymodel.cpp:51
void setSourceModel(QAbstractItemModel *sourceModel)
Definition: kidentityproxymodel.cpp:401
QModelIndex mapToSource(const QModelIndex &proxyIndex) const
Definition: kidentityproxymodel.cpp:299
Qt::ItemFlags flags(const QModelIndex &index) const
Definition: kcheckableproxymodel.cpp:70
void setSourceModel(QAbstractItemModel *sourceModel)
Definition: kcheckableproxymodel.cpp:112
virtual bool select(const QItemSelection &selection, QItemSelectionModel::SelectionFlags command)
Definition: kcheckableproxymodel.cpp:127
void setSelectionModel(QItemSelectionModel *itemSelectionModel)
Definition: kcheckableproxymodel.cpp:56
This file is part of the KDE documentation.
Documentation copyright © 1996-2014 The KDE developers.
Generated on Tue Oct 14 2014 22:49:14 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006
Documentation copyright © 1996-2014 The KDE developers.
Generated on Tue Oct 14 2014 22:49:14 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006
KDE's Doxygen guidelines are available online.