aboutsummaryrefslogtreecommitdiffstats
path: root/src/quick/items/qquickitemview_p_p.h
diff options
context:
space:
mode:
authorUlf Hermann <[email protected]>2021-10-28 16:06:08 +0200
committerUlf Hermann <[email protected]>2021-10-29 17:49:13 +0200
commit3193b20570408621d0cf9fa1665397f443d2d4d8 (patch)
tree26b98b3312a5ff92209f8657b82b041169910a92 /src/quick/items/qquickitemview_p_p.h
parent9fc480db9a02b0f1084719cc676b976efda18013 (diff)
QQuickItemView: avoid leaking of highlights and animators
It's unclear where exactly they leak, but the tst_snippets test in quickcontrols exposes it. Turning them into unique_ptrs is the clean solution anyway. They are clearly owned. Change-Id: I076ea86639b1e0ab3f688eb982b4cee6cb908f6b Reviewed-by: Fabian Kosmale <[email protected]>
Diffstat (limited to 'src/quick/items/qquickitemview_p_p.h')
-rw-r--r--src/quick/items/qquickitemview_p_p.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/quick/items/qquickitemview_p_p.h b/src/quick/items/qquickitemview_p_p.h
index b9b129a073..79d10fafc4 100644
--- a/src/quick/items/qquickitemview_p_p.h
+++ b/src/quick/items/qquickitemview_p_p.h
@@ -279,7 +279,7 @@ public:
QPauseAnimationJob bufferPause;
QQmlComponent *highlightComponent;
- FxViewItem *highlight;
+ std::unique_ptr<FxViewItem> highlight;
int highlightRange; // enum value
qreal highlightRangeStart;
qreal highlightRangeEnd;