|
|
|
|
@ -70,14 +70,14 @@ namespace Breeze |
|
|
|
|
//@{
|
|
|
|
|
|
|
|
|
|
//! flags
|
|
|
|
|
Qt::ItemFlags flags(const QModelIndex &index) const Q_DECL_OVERRIDE |
|
|
|
|
Qt::ItemFlags flags(const QModelIndex &index) const override |
|
|
|
|
{ |
|
|
|
|
if (!index.isValid()) return 0; |
|
|
|
|
return Qt::ItemIsEnabled | Qt::ItemIsSelectable; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
//! unique index for given row, column and parent index
|
|
|
|
|
QModelIndex index(int row, int column, const QModelIndex &parent = QModelIndex()) const Q_DECL_OVERRIDE |
|
|
|
|
QModelIndex index(int row, int column, const QModelIndex &parent = QModelIndex()) const override |
|
|
|
|
{ |
|
|
|
|
|
|
|
|
|
// check if index is valid
|
|
|
|
|
@ -92,11 +92,11 @@ namespace Breeze |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
//! index of parent
|
|
|
|
|
QModelIndex parent(const QModelIndex &) const Q_DECL_OVERRIDE |
|
|
|
|
QModelIndex parent(const QModelIndex &) const override |
|
|
|
|
{ return QModelIndex(); } |
|
|
|
|
|
|
|
|
|
//! number of rows below given index
|
|
|
|
|
int rowCount(const QModelIndex &parent = QModelIndex()) const Q_DECL_OVERRIDE |
|
|
|
|
int rowCount(const QModelIndex &parent = QModelIndex()) const override |
|
|
|
|
{ return parent.isValid() ? 0:_values.size(); } |
|
|
|
|
|
|
|
|
|
//@}
|
|
|
|
|
|