From 1327ded7478de7781bcfe57a2eb84dc0c749c91a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C4=99drzej=20Nowacki?= Date: Tue, 8 Jan 2013 13:07:16 +0100 Subject: Fix QVariant in a static build. The patch cases registration of QVariant handler for widgets. Task-number: QTBUG-28528 Change-Id: I645e8054bb96db0b92edf5df36f206ec1965ad40 Reviewed-by: Olivier Goffart Reviewed-by: Friedemann Kleint --- src/widgets/kernel/qapplication.cpp | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'src/widgets') diff --git a/src/widgets/kernel/qapplication.cpp b/src/widgets/kernel/qapplication.cpp index ed6262ce93..d558813f8e 100644 --- a/src/widgets/kernel/qapplication.cpp +++ b/src/widgets/kernel/qapplication.cpp @@ -579,6 +579,7 @@ void QApplicationPrivate::construct() void qRegisterGuiStateMachine(); void qUnregisterGuiStateMachine(); #endif +extern void qRegisterWidgetsVariant(); /*! \fn void QApplicationPrivate::initialize() @@ -590,6 +591,9 @@ void QApplicationPrivate::initialize() QWidgetPrivate::mapper = new QWidgetMapper; QWidgetPrivate::allWidgets = new QWidgetSet; + // needed for a static build. + qRegisterWidgetsVariant(); + if (application_type != QApplicationPrivate::Tty) (void) QApplication::style(); // trigger creation of application style #ifndef QT_NO_STATEMACHINE -- cgit v1.2.3