From 1ee1e4f6ac2ad337ee363a3e9e4db1e04e700f49 Mon Sep 17 00:00:00 2001 From: Andreas Buhr Date: Wed, 16 Feb 2022 11:58:37 +0100 Subject: QAbstractItemModel: make naming of arguments consistent The signals rowsAboutToBeMoved/rowsMoved have the same arguments, but use different argument names. This patch aligns the naming, making it consistent. Same for columnsAboutToBeMoved/columnsMoved. Change-Id: I1cefe54319e569b8d57f6579ae9d5c3e33b66dc2 Reviewed-by: David Faure --- src/corelib/itemmodels/qabstractitemmodel.cpp | 16 ++++++++-------- src/corelib/itemmodels/qabstractitemmodel.h | 4 ++-- 2 files changed, 10 insertions(+), 10 deletions(-) (limited to 'src/corelib/itemmodels') diff --git a/src/corelib/itemmodels/qabstractitemmodel.cpp b/src/corelib/itemmodels/qabstractitemmodel.cpp index c716648427..8c34734408 100644 --- a/src/corelib/itemmodels/qabstractitemmodel.cpp +++ b/src/corelib/itemmodels/qabstractitemmodel.cpp @@ -1859,13 +1859,13 @@ QAbstractItemModel::~QAbstractItemModel() */ /*! - \fn void QAbstractItemModel::rowsMoved(const QModelIndex &parent, int start, int end, const QModelIndex &destination, int row) + \fn void QAbstractItemModel::rowsMoved(const QModelIndex &sourceParent, int sourceStart, int sourceEnd, const QModelIndex &destinationParent, int destinationRow) \since 4.6 This signal is emitted after rows have been moved within the - model. The items between \a start and \a end - inclusive, under the given \a parent item have been moved to \a destination - starting at the row \a row. + model. The items between \a sourceStart and \a sourceEnd + inclusive, under the given \a sourceParent item have been moved to \a destinationParent + starting at the row \a destinationRow. \b{Note:} Components connected to this signal use it to adapt to changes in the model's dimensions. It can only be emitted by the QAbstractItemModel @@ -1891,13 +1891,13 @@ QAbstractItemModel::~QAbstractItemModel() */ /*! - \fn void QAbstractItemModel::columnsMoved(const QModelIndex &parent, int start, int end, const QModelIndex &destination, int column) + \fn void QAbstractItemModel::columnsMoved(const QModelIndex &sourceParent, int sourceStart, int sourceEnd, const QModelIndex &destinationParent, int destinationColumn) \since 4.6 This signal is emitted after columns have been moved within the - model. The items between \a start and \a end - inclusive, under the given \a parent item have been moved to \a destination - starting at the column \a column. + model. The items between \a sourceStart and \a sourceEnd + inclusive, under the given \a sourceParent item have been moved to \a destinationParent + starting at the column \a destinationColumn. \b{Note:} Components connected to this signal use it to adapt to changes in the model's dimensions. It can only be emitted by the QAbstractItemModel diff --git a/src/corelib/itemmodels/qabstractitemmodel.h b/src/corelib/itemmodels/qabstractitemmodel.h index f86a945c52..ece7d917c5 100644 --- a/src/corelib/itemmodels/qabstractitemmodel.h +++ b/src/corelib/itemmodels/qabstractitemmodel.h @@ -386,10 +386,10 @@ Q_SIGNALS: void modelReset(QPrivateSignal); void rowsAboutToBeMoved( const QModelIndex &sourceParent, int sourceStart, int sourceEnd, const QModelIndex &destinationParent, int destinationRow, QPrivateSignal); - void rowsMoved( const QModelIndex &parent, int start, int end, const QModelIndex &destination, int row, QPrivateSignal); + void rowsMoved( const QModelIndex &sourceParent, int sourceStart, int sourceEnd, const QModelIndex &destinationParent, int destinationRow, QPrivateSignal); void columnsAboutToBeMoved( const QModelIndex &sourceParent, int sourceStart, int sourceEnd, const QModelIndex &destinationParent, int destinationColumn, QPrivateSignal); - void columnsMoved( const QModelIndex &parent, int start, int end, const QModelIndex &destination, int column, QPrivateSignal); + void columnsMoved( const QModelIndex &sourceParent, int sourceStart, int sourceEnd, const QModelIndex &destinationParent, int destinationColumn, QPrivateSignal); public Q_SLOTS: virtual bool submit(); -- cgit v1.2.3