diff options
author | Luca Beldi <v.ronin@yahoo.it> | 2018-09-03 10:13:53 +0100 |
---|---|---|
committer | Luca Beldi <v.ronin@yahoo.it> | 2018-09-06 09:26:51 +0000 |
commit | 551e11c286b45d3e94b38f0e5df95f443c15f0bd (patch) | |
tree | f62b892efa3944ee0b090dcf7677cb206125407f /src/gui | |
parent | e5d028941339bbc5f5eaa2dfa5a2bb8d17353f24 (diff) |
Implement clearItemData in common models
A virtual method clearItemData was added to QAIM for Qt6.
This patch implements that method to all Qt concrete models for which
it makes sense.
Task-number: QTBUG-69616
Change-Id: If980fcfc36f723128bc56ec4587c5c3a338dbbcc
Reviewed-by: David Faure <david.faure@kdab.com>
Diffstat (limited to 'src/gui')
-rw-r--r-- | src/gui/itemmodels/qstandarditemmodel.cpp | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/gui/itemmodels/qstandarditemmodel.cpp b/src/gui/itemmodels/qstandarditemmodel.cpp index a771bffa2f..2288c26524 100644 --- a/src/gui/itemmodels/qstandarditemmodel.cpp +++ b/src/gui/itemmodels/qstandarditemmodel.cpp @@ -3005,11 +3005,17 @@ bool QStandardItemModel::setData(const QModelIndex &index, const QVariant &value return true; } +#if QT_VERSION >= QT_VERSION_CHECK(6, 0, 0) +/*! + \reimp + */ +#else /*! \since 5.12 Removes the data stored in all the roles for the given \a index. \sa setData(), data() */ +#endif bool QStandardItemModel::clearItemData(const QModelIndex &index) { if (!checkIndex(index, CheckIndexOption::IndexIsValid)) |