From be0a6ab4c8c20f94244b13b1445a80d726df0925 Mon Sep 17 00:00:00 2001 From: Paul Wicking Date: Thu, 21 Jun 2018 14:42:46 +0200 Subject: Doc: Improve description of QModelIndex::operator== MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit List the values that are compared by the comparison operator overloads, rather than the less specific "all values". Task-number: QTBUG-68877 Change-Id: Id4df02b9019e13113fd38a598b8349293fab7915 Reviewed-by: Giuseppe D'Angelo Reviewed-by: Topi Reiniƶ --- src/corelib/itemmodels/qabstractitemmodel.cpp | 18 ++++++++---------- 1 file changed, 8 insertions(+), 10 deletions(-) (limited to 'src/corelib/itemmodels') diff --git a/src/corelib/itemmodels/qabstractitemmodel.cpp b/src/corelib/itemmodels/qabstractitemmodel.cpp index d826110ec7..3a6f67521f 100644 --- a/src/corelib/itemmodels/qabstractitemmodel.cpp +++ b/src/corelib/itemmodels/qabstractitemmodel.cpp @@ -182,8 +182,8 @@ QPersistentModelIndex::~QPersistentModelIndex() Returns \c{true} if this persistent model index is equal to the \a other persistent model index; otherwise returns \c{false}. - All values in the persistent model index are used when comparing - with another persistent model index. + The internal data pointer, row, column, and model values in the persistent + model index are used when comparing with another persistent model index. */ bool QPersistentModelIndex::operator==(const QPersistentModelIndex &other) const @@ -199,8 +199,8 @@ bool QPersistentModelIndex::operator==(const QPersistentModelIndex &other) const Returns \c{true} if this persistent model index is smaller than the \a other persistent model index; otherwise returns \c{false}. - All values in the persistent model index are used when comparing - with another persistent model index. + The internal data pointer, row, column, and model values in the persistent + model index are used when comparing with another persistent model index. */ bool QPersistentModelIndex::operator<(const QPersistentModelIndex &other) const @@ -275,13 +275,11 @@ QPersistentModelIndex::operator const QModelIndex&() const } /*! - \fn bool QPersistentModelIndex::operator==(const QModelIndex &other) const - Returns \c{true} if this persistent model index refers to the same location as the \a other model index; otherwise returns \c{false}. - All values in the persistent model index are used when comparing with - another model index. + The internal data pointer, row, column, and model values in the persistent + model index are used when comparing with another model index. */ bool QPersistentModelIndex::operator==(const QModelIndex &other) const @@ -1167,8 +1165,8 @@ void QAbstractItemModel::resetInternalData() Returns \c{true} if this model index refers to the same location as the \a other model index; otherwise returns \c{false}. - All values in the model index are used when comparing with another model - index. + The internal data pointer, row, column, and model values are used when + comparing with another model index. */ -- cgit v1.2.3