From aec42f9953954d48a11465f56b5e5ee4987f3b44 Mon Sep 17 00:00:00 2001 From: Richard Moe Gustavsen Date: Sat, 23 Jun 2018 10:53:06 +0200 Subject: Revert "QQmlAdaptorModel: support dataChanged signals from multi-column models" No longer needed since TableView will switch to use QQmlTableInstanceModel. This reverts commit a5d2fb468cabff8dc0702c7ddcd9f5b08993b827. Change-Id: I10c6217627a77beebd99cfa5668db05bbbe4ed15 Reviewed-by: Mitch Curtis --- src/qml/types/qqmldelegatemodel.cpp | 11 ++--------- 1 file changed, 2 insertions(+), 9 deletions(-) (limited to 'src/qml/types/qqmldelegatemodel.cpp') diff --git a/src/qml/types/qqmldelegatemodel.cpp b/src/qml/types/qqmldelegatemodel.cpp index 0d82cca001..7a128d7070 100644 --- a/src/qml/types/qqmldelegatemodel.cpp +++ b/src/qml/types/qqmldelegatemodel.cpp @@ -1680,15 +1680,8 @@ void QQmlDelegateModel::_q_rowsMoved( void QQmlDelegateModel::_q_dataChanged(const QModelIndex &begin, const QModelIndex &end, const QVector &roles) { Q_D(QQmlDelegateModel); - if (begin.parent() != d->m_adaptorModel.rootIndex) - return; - - int rowCount = end.row() - begin.row() + 1; - - for (int col = begin.column(); col <= end.column(); ++col) { - int startIndex = d->m_adaptorModel.indexAt(begin.row(), col); - _q_itemsChanged(startIndex, rowCount, roles); - } + if (begin.parent() == d->m_adaptorModel.rootIndex) + _q_itemsChanged(begin.row(), end.row() - begin.row() + 1, roles); } bool QQmlDelegateModel::isDescendantOf(const QPersistentModelIndex& desc, const QList< QPersistentModelIndex >& parents) const -- cgit v1.2.3