aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGiuseppe D'Angelo <giuseppe.dangelo@kdab.com>2021-04-20 20:42:16 +0200
committerQt Cherry-pick Bot <cherrypick_bot@qt-project.org>2021-04-20 21:26:23 +0000
commit6b5021c9904ac35797f3fcce95023897c3672fbf (patch)
treec01fcc9842d4360bdd6ea6477181201dfc8a5e64
parent67833d929bd8d2ad37565fd0121d70f0b9d13079 (diff)
QQmlDelegateModel: build fix
Capturing of `this` via `[=]` is deprecated in C++20. Be explicit. Change-Id: Ic3b0a14c8eea83afbd17e97a2e3cdefbce045ff2 Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io> (cherry picked from commit dcdbd0b0af345c1b919ba9f09b5e591e5d00f4cb) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
-rw-r--r--src/qmlmodels/qqmldelegatemodel.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/qmlmodels/qqmldelegatemodel.cpp b/src/qmlmodels/qqmldelegatemodel.cpp
index 7ef07e6352..7abd1cea62 100644
--- a/src/qmlmodels/qqmldelegatemodel.cpp
+++ b/src/qmlmodels/qqmldelegatemodel.cpp
@@ -1101,7 +1101,7 @@ void QQmlDelegateModelPrivate::reuseItem(QQmlDelegateModelItem *item, int newMod
void QQmlDelegateModelPrivate::drainReusableItemsPool(int maxPoolTime)
{
- m_reusableItemsPool.drain(maxPoolTime, [=](QQmlDelegateModelItem *cacheItem){ destroyCacheItem(cacheItem); });
+ m_reusableItemsPool.drain(maxPoolTime, [this](QQmlDelegateModelItem *cacheItem){ destroyCacheItem(cacheItem); });
}
void QQmlDelegateModel::drainReusableItemsPool(int maxPoolTime)