From d037d25c3d5236623371cf051aaf6a9e59792ba7 Mon Sep 17 00:00:00 2001 From: Girish Ramakrishnan Date: Fri, 13 Apr 2012 15:53:50 -0700 Subject: [PATCH] api: fix constness of QOpenGLContext::getProcAddress Should be const just like Qt4's QGLContext::getProcAddress. Change-Id: I273467d5cf852cd49f48cec3f335c4ddac795363 Reviewed-by: Gunnar Sletta --- src/gui/kernel/qopenglcontext.cpp | 4 ++-- src/gui/kernel/qopenglcontext.h | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/gui/kernel/qopenglcontext.cpp b/src/gui/kernel/qopenglcontext.cpp index 29f46aefd6..4668f9e750 100644 --- a/src/gui/kernel/qopenglcontext.cpp +++ b/src/gui/kernel/qopenglcontext.cpp @@ -541,9 +541,9 @@ void QOpenGLContext::swapBuffers(QSurface *surface) Returns 0 if no such function can be found. */ -QFunctionPointer QOpenGLContext::getProcAddress(const QByteArray &procName) +QFunctionPointer QOpenGLContext::getProcAddress(const QByteArray &procName) const { - Q_D(QOpenGLContext); + Q_D(const QOpenGLContext); if (!d->platformGLContext) return 0; return d->platformGLContext->getProcAddress(procName); diff --git a/src/gui/kernel/qopenglcontext.h b/src/gui/kernel/qopenglcontext.h index 5e1cd17635..efb65ae3e7 100644 --- a/src/gui/kernel/qopenglcontext.h +++ b/src/gui/kernel/qopenglcontext.h @@ -115,7 +115,7 @@ public: void doneCurrent(); void swapBuffers(QSurface *surface); - QFunctionPointer getProcAddress(const QByteArray &procName); + QFunctionPointer getProcAddress(const QByteArray &procName) const; QSurface *surface() const;