diff options
author | Sergio Martins <sergio.martins@kdab.com> | 2015-07-15 15:43:09 +0100 |
---|---|---|
committer | Gabriel de Dietrich <gabriel.dedietrich@theqtcompany.com> | 2015-07-15 15:52:04 +0000 |
commit | 4572541637f7ce1f93f3b4e0f4d0ab69b01f6ed2 (patch) | |
tree | 930e32bff93678afa2ba4f69b8df14c1034c36fd /src/controls/qquickpopupwindow_p.h | |
parent | 835c8459c0448f211e2692dfbfaa65e46cd05fce (diff) | |
download | qtquickcontrols-4572541637f7ce1f93f3b4e0f4d0ab69b01f6ed2.tar.gz |
Protect the content item with a QPointer since we don't own it.
Fixes a CI crash reproducible at least on Ubuntu
Change-Id: I45a59054c20c3a99da30b79d33e24184bf328db9
Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@theqtcompany.com>
Diffstat (limited to 'src/controls/qquickpopupwindow_p.h')
-rw-r--r-- | src/controls/qquickpopupwindow_p.h | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/controls/qquickpopupwindow_p.h b/src/controls/qquickpopupwindow_p.h index b95275c0..617df53d 100644 --- a/src/controls/qquickpopupwindow_p.h +++ b/src/controls/qquickpopupwindow_p.h @@ -37,12 +37,12 @@ #ifndef QQUICKPOPUPWINDOW_H #define QQUICKPOPUPWINDOW_H +#include <QtCore/QPointer> +#include <QtQuick/qquickitem.h> #include <QtQuick/qquickwindow.h> QT_BEGIN_NAMESPACE -class QQuickItem; - class QQuickPopupWindow : public QQuickWindow { Q_OBJECT @@ -84,7 +84,7 @@ private: void forwardEventToTransientParent(QMouseEvent *); QQuickItem *m_parentItem; - QQuickItem *m_contentItem; + QPointer<QQuickItem> m_contentItem; bool m_mouseMoved; bool m_needsActivatedEvent; bool m_dismissed; |