1 /* 2 * DQt - D bindings for the Qt Toolkit 3 * 4 * GNU Lesser General Public License Usage 5 * This file may be used under the terms of the GNU Lesser 6 * General Public License version 3 as published by the Free Software 7 * Foundation and appearing in the file LICENSE.LGPL3 included in the 8 * packaging of this file. Please review the following information to 9 * ensure the GNU Lesser General Public License version 3 requirements 10 * will be met: https://www.gnu.org/licenses/lgpl-3.0.html. 11 */ 12 module qt.core.concatenatetablesproxymodel; 13 extern(C++): 14 15 import qt.config; 16 import qt.core.abstractitemmodel; 17 import qt.core.list; 18 import qt.core.map; 19 import qt.core.mimedata; 20 import qt.core.namespace; 21 import qt.core.object; 22 import qt.core.size; 23 import qt.core.stringlist; 24 import qt.core.variant; 25 import qt.helpers; 26 27 /+ QT_REQUIRE_CONFIG(concatenatetablesproxymodel); +/ 28 29 30 extern(C++, class) struct QConcatenateTablesProxyModelPrivate; 31 32 /// Binding for C++ class [QConcatenateTablesProxyModel](https://doc.qt.io/qt-6/qconcatenatetablesproxymodel.html). 33 class /+ Q_CORE_EXPORT +/ QConcatenateTablesProxyModel : QAbstractItemModel 34 { 35 mixin(Q_OBJECT); 36 37 public: 38 /+ explicit +/this(QObject parent = null); 39 ~this(); 40 41 final QList!(QAbstractItemModel) sourceModels() const; 42 /+ Q_SCRIPTABLE +/ @QScriptable final void addSourceModel(QAbstractItemModel sourceModel); 43 /+ Q_SCRIPTABLE +/ @QScriptable final void removeSourceModel(QAbstractItemModel sourceModel); 44 45 final QModelIndex mapFromSource(ref const(QModelIndex) sourceIndex) const; 46 final QModelIndex mapToSource(ref const(QModelIndex) proxyIndex) const; 47 48 override QVariant data(ref const(QModelIndex) index, int role = /+ Qt:: +/qt.core.namespace.ItemDataRole.DisplayRole) const; 49 override bool setData(ref const(QModelIndex) index, ref const(QVariant) value, int role = /+ Qt:: +/qt.core.namespace.ItemDataRole.EditRole); 50 override QMap!(int, QVariant) itemData(ref const(QModelIndex) proxyIndex) const; 51 override bool setItemData(ref const(QModelIndex) index, ref const(QMap!(int, QVariant)) roles); 52 override /+ Qt:: +/qt.core.namespace.ItemFlags flags(ref const(QModelIndex) index) const; 53 override QModelIndex index(int row, int column, ref const(QModelIndex) parent = globalInitVar!QModelIndex) const; 54 override QModelIndex parent(ref const(QModelIndex) index) const; 55 override int rowCount(ref const(QModelIndex) parent = globalInitVar!QModelIndex) const; 56 override QVariant headerData(int section, /+ Qt:: +/qt.core.namespace.Orientation orientation, int role = /+ Qt:: +/qt.core.namespace.ItemDataRole.DisplayRole) const; 57 override int columnCount(ref const(QModelIndex) parent = globalInitVar!QModelIndex) const; 58 override QStringList mimeTypes() const; 59 override QMimeData mimeData(ref const(QModelIndexList) indexes) const; 60 mixin(changeWindowsMangling(q{mangleClassesTailConst}, q{ 61 override bool canDropMimeData(const(QMimeData) data, /+ Qt:: +/qt.core.namespace.DropAction action, int row, int column, ref const(QModelIndex) parent) const; 62 })); 63 mixin(changeWindowsMangling(q{mangleClassesTailConst}, q{ 64 override bool dropMimeData(const(QMimeData) data, /+ Qt:: +/qt.core.namespace.DropAction action, int row, int column, ref const(QModelIndex) parent); 65 })); 66 override QSize span(ref const(QModelIndex) index) const; 67 68 private: 69 /+ Q_DECLARE_PRIVATE(QConcatenateTablesProxyModel) +/ 70 /+ Q_DISABLE_COPY(QConcatenateTablesProxyModel) +/ 71 72 /+ Q_PRIVATE_SLOT(d_func(), void _q_slotRowsAboutToBeInserted(const QModelIndex &, int start, int end)) 73 Q_PRIVATE_SLOT(d_func(), void _q_slotRowsInserted(const QModelIndex &, int start, int end)) 74 Q_PRIVATE_SLOT(d_func(), void _q_slotRowsAboutToBeRemoved(const QModelIndex &, int start, int end)) 75 Q_PRIVATE_SLOT(d_func(), void _q_slotRowsRemoved(const QModelIndex &, int start, int end)) 76 Q_PRIVATE_SLOT(d_func(), void _q_slotColumnsAboutToBeInserted(const QModelIndex &parent, int start, int end)) 77 Q_PRIVATE_SLOT(d_func(), void _q_slotColumnsInserted(const QModelIndex &parent, int, int)) 78 Q_PRIVATE_SLOT(d_func(), void _q_slotColumnsAboutToBeRemoved(const QModelIndex &parent, int start, int end)) 79 Q_PRIVATE_SLOT(d_func(), void _q_slotColumnsRemoved(const QModelIndex &parent, int, int)) 80 Q_PRIVATE_SLOT(d_func(), 81 void _q_slotDataChanged(const QModelIndex &from, const QModelIndex &to, const QList<int> &roles)) 82 Q_PRIVATE_SLOT(d_func(), void _q_slotSourceLayoutAboutToBeChanged(QList<QPersistentModelIndex>, QAbstractItemModel::LayoutChangeHint)) 83 Q_PRIVATE_SLOT(d_func(), void _q_slotSourceLayoutChanged(const QList<QPersistentModelIndex> &, QAbstractItemModel::LayoutChangeHint)) 84 Q_PRIVATE_SLOT(d_func(), void _q_slotModelAboutToBeReset()) 85 Q_PRIVATE_SLOT(d_func(), void _q_slotModelReset()) +/ 86 mixin(CREATE_CONVENIENCE_WRAPPERS); 87 } 88