From c07559bf5b352932dc4972a61c2c5f9b4ddc3c99 Mon Sep 17 00:00:00 2001 From: Friedemann Kleint Date: Wed, 17 Dec 2014 08:54:11 +0100 Subject: QOpenGLContext: Use static invocation of QGuiApplication::platformNativeInterface(). Fix MSVC warning (release build): qopenglcontext.cpp(1116) : warning C4189: 'app' : local variable is initialized but not referenced Change-Id: I00fa5237bbac4c0e3bb63ea9d3e5096e05dbe1be Reviewed-by: Laszlo Agocs --- src/gui/kernel/qopenglcontext.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'src/gui/kernel/qopenglcontext.cpp') diff --git a/src/gui/kernel/qopenglcontext.cpp b/src/gui/kernel/qopenglcontext.cpp index 1a8a534e11..c01e1c95dd 100644 --- a/src/gui/kernel/qopenglcontext.cpp +++ b/src/gui/kernel/qopenglcontext.cpp @@ -1113,9 +1113,9 @@ void QOpenGLContext::deleteQGLContext() void *QOpenGLContext::openGLModuleHandle() { #ifdef QT_OPENGL_DYNAMIC - QGuiApplication *app = qGuiApp; - Q_ASSERT(app); - return app->platformNativeInterface()->nativeResourceForIntegration(QByteArrayLiteral("glhandle")); + QPlatformNativeInterface *ni = QGuiApplication::platformNativeInterface(); + Q_ASSERT(ni); + return ni->nativeResourceForIntegration(QByteArrayLiteral("glhandle")); #else return 0; #endif -- cgit v1.2.3