1 #ifndef CSM_WOLRD_NESTEDTABLEPROXYMODEL_H
2 #define CSM_WOLRD_NESTEDTABLEPROXYMODEL_H
6 #include <QAbstractProxyModel>
42 virtual QModelIndex
mapFromSource(
const QModelIndex& sourceIndex)
const;
44 virtual QModelIndex
mapToSource(
const QModelIndex& proxyIndex)
const;
50 virtual QModelIndex
index(
int row,
int column,
const QModelIndex&
parent = QModelIndex())
const;
52 virtual QModelIndex
parent(
const QModelIndex&
index)
const;
54 virtual QVariant
headerData (
int section, Qt::Orientation orientation,
int role)
const;
56 virtual QVariant
data(
const QModelIndex &
index,
int role = Qt::DisplayRole)
const;
58 virtual bool setData (
const QModelIndex &
index,
const QVariant & value,
int role = Qt::EditRole);
60 virtual Qt::ItemFlags
flags(
const QModelIndex&
index)
const;
int getParentColumn() const
Definition: nestedtableproxymodel.cpp:122
virtual int rowCount(const QModelIndex &parent) const
Definition: nestedtableproxymodel.cpp:60
NestedTableProxyModel(const QModelIndex &parent, ColumnBase::Display displayType, IdTree *parentModel)
Definition: nestedtableproxymodel.cpp:6
void forwardRowsInserted(const QModelIndex &parent, int first, int last)
Definition: nestedtableproxymodel.cpp:141
void forwardRowsAboutToRemoved(const QModelIndex &parent, int first, int last)
Definition: nestedtableproxymodel.cpp:156
Display
Definition: columnbase.hpp:39
virtual QModelIndex parent(const QModelIndex &index) const
Definition: nestedtableproxymodel.cpp:87
std::string mId
Definition: nestedtableproxymodel.hpp:28
virtual QVariant data(const QModelIndex &index, int role=Qt::DisplayRole) const
Definition: nestedtableproxymodel.cpp:99
void forwardDataChanged(const QModelIndex &topLeft, const QModelIndex &bottomRight)
Definition: nestedtableproxymodel.cpp:185
virtual QModelIndex index(int row, int column, const QModelIndex &parent=QModelIndex()) const
Definition: nestedtableproxymodel.cpp:74
CSMWorld::IdTree * model() const
Definition: nestedtableproxymodel.cpp:127
virtual bool setData(const QModelIndex &index, const QVariant &value, int role=Qt::EditRole)
Definition: nestedtableproxymodel.cpp:107
void forwardResetEnd(const QString &id)
Definition: nestedtableproxymodel.cpp:179
std::string getParentId() const
Definition: nestedtableproxymodel.cpp:117
virtual QVariant headerData(int section, Qt::Orientation orientation, int role) const
Definition: nestedtableproxymodel.cpp:92
Definition: nestedtableproxymodel.hpp:22
void forwardResetStart(const QString &id)
Definition: nestedtableproxymodel.cpp:173
const int mParentColumn
Definition: nestedtableproxymodel.hpp:26
virtual Qt::ItemFlags flags(const QModelIndex &index) const
Definition: nestedtableproxymodel.cpp:112
IdTree * mMainModel
Definition: nestedtableproxymodel.hpp:27
void setupHeaderVectors(ColumnBase::Display columnId)
virtual QModelIndex mapToSource(const QModelIndex &proxyIndex) const
Definition: nestedtableproxymodel.cpp:54
bool indexIsParent(const QModelIndex &index)
Definition: nestedtableproxymodel.cpp:149
Definition: idtree.hpp:25
virtual int columnCount(const QModelIndex &parent) const
Definition: nestedtableproxymodel.cpp:67
virtual QModelIndex mapFromSource(const QModelIndex &sourceIndex) const
Definition: nestedtableproxymodel.cpp:40
void forwardRowsRemoved(const QModelIndex &parent, int first, int last)
Definition: nestedtableproxymodel.cpp:165
void forwardRowsAboutToInserted(const QModelIndex &parent, int first, int last)
Definition: nestedtableproxymodel.cpp:132