#ifndef PYTHONQTWRAPPER_QABSTRACTITEMMODEL_H #define PYTHONQTWRAPPER_QABSTRACTITEMMODEL_H #include #include #include #include #include #include #include #include #include #include #include #include #include class PythonQtShell_QAbstractItemModel : public QAbstractItemModel { public: PythonQtShell_QAbstractItemModel(QObject* parent = 0):QAbstractItemModel(parent),_wrapper(NULL) {}; virtual QModelIndex buddy(const QModelIndex& index) const; virtual bool canFetchMore(const QModelIndex& parent) const; virtual void childEvent(QChildEvent* arg__1); virtual int columnCount(const QModelIndex& parent = QModelIndex()) const; virtual void customEvent(QEvent* arg__1); virtual QVariant data(const QModelIndex& index, int role = Qt::DisplayRole) const; virtual bool dropMimeData(const QMimeData* data, Qt::DropAction action, int row, int column, const QModelIndex& parent); virtual bool event(QEvent* arg__1); virtual bool eventFilter(QObject* arg__1, QEvent* arg__2); virtual void fetchMore(const QModelIndex& parent); virtual Qt::ItemFlags flags(const QModelIndex& index) const; virtual bool hasChildren(const QModelIndex& parent = QModelIndex()) const; virtual QVariant headerData(int section, Qt::Orientation orientation, int role = Qt::DisplayRole) const; virtual QModelIndex index(int row, int column, const QModelIndex& parent = QModelIndex()) const; virtual bool insertColumns(int column, int count, const QModelIndex& parent = QModelIndex()); virtual bool insertRows(int row, int count, const QModelIndex& parent = QModelIndex()); virtual QMap itemData(const QModelIndex& index) const; virtual QList match(const QModelIndex& start, int role, const QVariant& value, int hits = 1, Qt::MatchFlags flags = Qt::MatchFlags(Qt::MatchStartsWith|Qt::MatchWrap)) const; virtual QMimeData* mimeData(const QList& indexes) const; virtual QStringList mimeTypes() const; virtual QModelIndex parent(const QModelIndex& child) const; virtual bool removeColumns(int column, int count, const QModelIndex& parent = QModelIndex()); virtual bool removeRows(int row, int count, const QModelIndex& parent = QModelIndex()); virtual void revert(); virtual int rowCount(const QModelIndex& parent = QModelIndex()) const; virtual bool setData(const QModelIndex& index, const QVariant& value, int role = Qt::EditRole); virtual bool setHeaderData(int section, Qt::Orientation orientation, const QVariant& value, int role = Qt::EditRole); virtual bool setItemData(const QModelIndex& index, const QMap& roles); virtual void sort(int column, Qt::SortOrder order = Qt::AscendingOrder); virtual QSize span(const QModelIndex& index) const; virtual bool submit(); virtual Qt::DropActions supportedDropActions() const; virtual void timerEvent(QTimerEvent* arg__1); PythonQtInstanceWrapper* _wrapper; }; class PythonQtPublicPromoter_QAbstractItemModel : public QAbstractItemModel { public: inline QMimeData* promoted_mimeData(const QList& indexes) const { return QAbstractItemModel::mimeData(indexes); } inline void promoted_revert() { QAbstractItemModel::revert(); } inline bool promoted_canFetchMore(const QModelIndex& parent) const { return QAbstractItemModel::canFetchMore(parent); } inline QVariant promoted_headerData(int section, Qt::Orientation orientation, int role = Qt::DisplayRole) const { return QAbstractItemModel::headerData(section, orientation, role); } inline QModelIndex promoted_buddy(const QModelIndex& index) const { return QAbstractItemModel::buddy(index); } inline bool promoted_insertRows(int row, int count, const QModelIndex& parent = QModelIndex()) { return QAbstractItemModel::insertRows(row, count, parent); } inline bool promoted_submit() { return QAbstractItemModel::submit(); } inline Qt::ItemFlags promoted_flags(const QModelIndex& index) const { return QAbstractItemModel::flags(index); } inline bool promoted_dropMimeData(const QMimeData* data, Qt::DropAction action, int row, int column, const QModelIndex& parent) { return QAbstractItemModel::dropMimeData(data, action, row, column, parent); } inline QStringList promoted_mimeTypes() const { return QAbstractItemModel::mimeTypes(); } inline bool promoted_insertColumns(int column, int count, const QModelIndex& parent = QModelIndex()) { return QAbstractItemModel::insertColumns(column, count, parent); } inline QList promoted_match(const QModelIndex& start, int role, const QVariant& value, int hits = 1, Qt::MatchFlags flags = Qt::MatchFlags(Qt::MatchStartsWith|Qt::MatchWrap)) const { return QAbstractItemModel::match(start, role, value, hits, flags); } inline bool promoted_setItemData(const QModelIndex& index, const QMap& roles) { return QAbstractItemModel::setItemData(index, roles); } inline void promoted_sort(int column, Qt::SortOrder order = Qt::AscendingOrder) { QAbstractItemModel::sort(column, order); } inline Qt::DropActions promoted_supportedDropActions() const { return QAbstractItemModel::supportedDropActions(); } inline bool promoted_removeRows(int row, int count, const QModelIndex& parent = QModelIndex()) { return QAbstractItemModel::removeRows(row, count, parent); } inline bool promoted_setData(const QModelIndex& index, const QVariant& value, int role = Qt::EditRole) { return QAbstractItemModel::setData(index, value, role); } inline bool promoted_removeColumns(int column, int count, const QModelIndex& parent = QModelIndex()) { return QAbstractItemModel::removeColumns(column, count, parent); } inline QSize promoted_span(const QModelIndex& index) const { return QAbstractItemModel::span(index); } inline bool promoted_hasChildren(const QModelIndex& parent = QModelIndex()) const { return QAbstractItemModel::hasChildren(parent); } inline void promoted_fetchMore(const QModelIndex& parent) { QAbstractItemModel::fetchMore(parent); } inline QMap promoted_itemData(const QModelIndex& index) const { return QAbstractItemModel::itemData(index); } inline bool promoted_setHeaderData(int section, Qt::Orientation orientation, const QVariant& value, int role = Qt::EditRole) { return QAbstractItemModel::setHeaderData(section, orientation, value, role); } }; class PythonQtWrapper_QAbstractItemModel : public QObject { Q_OBJECT public: public slots: QAbstractItemModel* new_QAbstractItemModel(QObject* parent = 0); void delete_QAbstractItemModel(QAbstractItemModel* obj) { delete obj; } QMimeData* mimeData(QAbstractItemModel* theWrappedObject, const QList& indexes) const; bool removeRow(QAbstractItemModel* theWrappedObject, int row, const QModelIndex& parent = QModelIndex()); bool insertRow(QAbstractItemModel* theWrappedObject, int row, const QModelIndex& parent = QModelIndex()); void setSupportedDragActions(QAbstractItemModel* theWrappedObject, Qt::DropActions arg__1); bool canFetchMore(QAbstractItemModel* theWrappedObject, const QModelIndex& parent) const; QVariant headerData(QAbstractItemModel* theWrappedObject, int section, Qt::Orientation orientation, int role = Qt::DisplayRole) const; QModelIndex sibling(QAbstractItemModel* theWrappedObject, int row, int column, const QModelIndex& idx) const; QModelIndex buddy(QAbstractItemModel* theWrappedObject, const QModelIndex& index) const; bool removeColumn(QAbstractItemModel* theWrappedObject, int column, const QModelIndex& parent = QModelIndex()); bool insertRows(QAbstractItemModel* theWrappedObject, int row, int count, const QModelIndex& parent = QModelIndex()); Qt::ItemFlags flags(QAbstractItemModel* theWrappedObject, const QModelIndex& index) const; QObject* parent(QAbstractItemModel* theWrappedObject) const; bool dropMimeData(QAbstractItemModel* theWrappedObject, const QMimeData* data, Qt::DropAction action, int row, int column, const QModelIndex& parent); QStringList mimeTypes(QAbstractItemModel* theWrappedObject) const; bool insertColumns(QAbstractItemModel* theWrappedObject, int column, int count, const QModelIndex& parent = QModelIndex()); QList match(QAbstractItemModel* theWrappedObject, const QModelIndex& start, int role, const QVariant& value, int hits = 1, Qt::MatchFlags flags = Qt::MatchFlags(Qt::MatchStartsWith|Qt::MatchWrap)) const; bool setItemData(QAbstractItemModel* theWrappedObject, const QModelIndex& index, const QMap& roles); bool insertColumn(QAbstractItemModel* theWrappedObject, int column, const QModelIndex& parent = QModelIndex()); bool hasIndex(QAbstractItemModel* theWrappedObject, int row, int column, const QModelIndex& parent = QModelIndex()) const; void sort(QAbstractItemModel* theWrappedObject, int column, Qt::SortOrder order = Qt::AscendingOrder); Qt::DropActions supportedDropActions(QAbstractItemModel* theWrappedObject) const; bool removeRows(QAbstractItemModel* theWrappedObject, int row, int count, const QModelIndex& parent = QModelIndex()); bool setData(QAbstractItemModel* theWrappedObject, const QModelIndex& index, const QVariant& value, int role = Qt::EditRole); bool removeColumns(QAbstractItemModel* theWrappedObject, int column, int count, const QModelIndex& parent = QModelIndex()); Qt::DropActions supportedDragActions(QAbstractItemModel* theWrappedObject) const; QSize span(QAbstractItemModel* theWrappedObject, const QModelIndex& index) const; bool hasChildren(QAbstractItemModel* theWrappedObject, const QModelIndex& parent = QModelIndex()) const; void fetchMore(QAbstractItemModel* theWrappedObject, const QModelIndex& parent); QMap itemData(QAbstractItemModel* theWrappedObject, const QModelIndex& index) const; bool setHeaderData(QAbstractItemModel* theWrappedObject, int section, Qt::Orientation orientation, const QVariant& value, int role = Qt::EditRole); }; #endif // PYTHONQTWRAPPER_QABSTRACTITEMMODEL_H