summaryrefslogtreecommitdiffstats
path: root/src/widgets/kernel/qstackedlayout.cpp
diff options
context:
space:
mode:
authorLiang Qi <liang.qi@qt.io>2016-09-28 11:51:35 +0200
committerLiang Qi <liang.qi@qt.io>2016-09-28 11:51:35 +0200
commite918334045612ec2c7c6203845ad05c4a1972e87 (patch)
treeb59bf3a173c6bfa58c3ba9b5bb80df4a093247dc /src/widgets/kernel/qstackedlayout.cpp
parente3cbf0f1962958457f6e09fcfdc92d8cac4b6511 (diff)
parentcf0119bb69592d58ca7e6a75753799ebae61e4b5 (diff)
Merge remote-tracking branch 'origin/5.6' into 5.7
Conflicts: src/widgets/dialogs/qcolordialog.cpp src/widgets/dialogs/qfiledialog.cpp tests/auto/network/ssl/qsslsocket/tst_qsslsocket.cpp Change-Id: I34bc8a990f8f526889a95a5c7099ef557b9681ad
Diffstat (limited to 'src/widgets/kernel/qstackedlayout.cpp')
-rw-r--r--src/widgets/kernel/qstackedlayout.cpp12
1 files changed, 4 insertions, 8 deletions
diff --git a/src/widgets/kernel/qstackedlayout.cpp b/src/widgets/kernel/qstackedlayout.cpp
index 006b3e8588..d9c1c524d7 100644
--- a/src/widgets/kernel/qstackedlayout.cpp
+++ b/src/widgets/kernel/qstackedlayout.cpp
@@ -41,7 +41,7 @@
#include "qlayout_p.h"
#include <qlist.h>
-#include <qwidget.h>
+#include "private/qwidget_p.h"
#include "private/qlayoutengine_p.h"
QT_BEGIN_NAMESPACE
@@ -251,14 +251,10 @@ QLayoutItem *QStackedLayout::itemAt(int index) const
// Code that enables proper handling of the case that takeAt() is
// called somewhere inside QObject destructor (can't call hide()
// on the object then)
-
-class QtFriendlyLayoutWidget : public QWidget
+static bool qt_wasDeleted(const QWidget *w)
{
-public:
- inline bool wasDeleted() const { return d_ptr->wasDeleted; }
-};
-
-static bool qt_wasDeleted(const QWidget *w) { return static_cast<const QtFriendlyLayoutWidget*>(w)->wasDeleted(); }
+ return QWidgetPrivate::get(w)->wasDeleted;
+}
/*!