diff options
Diffstat (limited to 'src/gui/kernel/qopenglcontext.cpp')
-rw-r--r-- | src/gui/kernel/qopenglcontext.cpp | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/src/gui/kernel/qopenglcontext.cpp b/src/gui/kernel/qopenglcontext.cpp index be04513de6..4847a62b0f 100644 --- a/src/gui/kernel/qopenglcontext.cpp +++ b/src/gui/kernel/qopenglcontext.cpp @@ -414,15 +414,14 @@ int QOpenGLContextPrivate::maxTextureSize() /*! Returns the last context which called makeCurrent in the current thread, - or 0, if no context is current. + or \nullptr, if no context is current. */ QOpenGLContext* QOpenGLContext::currentContext() { QGuiGLThreadContext *threadContext = qwindow_context_storage()->localData(); - if (threadContext) { + if (threadContext) return threadContext->context; - } - return 0; + return nullptr; } /*! |