summaryrefslogtreecommitdiffstats
path: root/src/gui/kernel/qopenglcontext.cpp
diff options
context:
space:
mode:
authorTor Arne Vestbø <tor.arne.vestbo@qt.io>2021-07-14 00:50:29 +0200
committerTor Arne Vestbø <tor.arne.vestbo@qt.io>2021-07-17 02:23:17 +0200
commit0e7212460ba7fab19a47f960b09a011973a7c475 (patch)
tree6801ba8a3e6e43c1a924411b965248e6f7bc2f8a /src/gui/kernel/qopenglcontext.cpp
parent8ebd4a1da820cff0e499258f79a3fc139ea06b77 (diff)
Use member function instead of template function to resolve native interface
The use of a freestanding function is not needed now that the name doesn't alias the nativeInterface accessor function, and was just adding complexity to the machinery. People not familiar with the code will have an easier time following the flow through the helper member function, and we no longer need to declare our own export macros. Pick-to: 6.2 Change-Id: I17530b7e89939cfc19ab8ffaa076b7129ae02dcf Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
Diffstat (limited to 'src/gui/kernel/qopenglcontext.cpp')
-rw-r--r--src/gui/kernel/qopenglcontext.cpp7
1 files changed, 3 insertions, 4 deletions
diff --git a/src/gui/kernel/qopenglcontext.cpp b/src/gui/kernel/qopenglcontext.cpp
index eef85bf0d0..bdbd18f771 100644
--- a/src/gui/kernel/qopenglcontext.cpp
+++ b/src/gui/kernel/qopenglcontext.cpp
@@ -1312,12 +1312,11 @@ QDebug operator<<(QDebug debug, const QOpenGLContextGroup *cg)
using namespace QNativeInterface;
-template <>
-Q_NATIVE_INTERFACE_EXPORT void *QNativeInterface::Private::resolveInterface(const QOpenGLContext *that, const char *name, int revision)
+void *QOpenGLContext::resolveInterface(const char *name, int revision) const
{
- Q_UNUSED(that); Q_UNUSED(name); Q_UNUSED(revision);
+ Q_UNUSED(name); Q_UNUSED(revision);
- auto *platformContext = that->handle();
+ auto *platformContext = handle();
Q_UNUSED(platformContext);
#if defined(Q_OS_MACOS)