aboutsummaryrefslogtreecommitdiffstats
path: root/src/qml/types/qqmldelegatemodel_p_p.h
diff options
context:
space:
mode:
authorUlf Hermann <ulf.hermann@qt.io>2019-02-13 13:31:07 +0100
committerUlf Hermann <ulf.hermann@qt.io>2019-02-14 08:01:28 +0000
commitdbc811e164019b5f9ce371cb7b49d695644f6a90 (patch)
treecf73cd456d27ec35d16239f94ba80b89775d3408 /src/qml/types/qqmldelegatemodel_p_p.h
parent0148243a77a42de1ba6170a1da3977b3026c1927 (diff)
DelegateModel: Zero foreign context objects when they are deleted
If we keep plain pointers to objects we don't own, we need to zero them when something else deletes them. Fixes: QTBUG-73733 Change-Id: Ib4f3e144f10f70ab6cf44af4ffa62725470d3972 Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
Diffstat (limited to 'src/qml/types/qqmldelegatemodel_p_p.h')
-rw-r--r--src/qml/types/qqmldelegatemodel_p_p.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/qml/types/qqmldelegatemodel_p_p.h b/src/qml/types/qqmldelegatemodel_p_p.h
index 2d6fdf228e..5e480f4df6 100644
--- a/src/qml/types/qqmldelegatemodel_p_p.h
+++ b/src/qml/types/qqmldelegatemodel_p_p.h
@@ -106,6 +106,7 @@ public:
void referenceObject() { ++objectRef; }
bool releaseObject() { return --objectRef == 0 && !(groups & Compositor::PersistedFlag); }
bool isObjectReferenced() const { return objectRef != 0 || (groups & Compositor::PersistedFlag); }
+ void childContextObjectDestroyed(QObject *childContextObject);
bool isReferenced() const {
return scriptRef