summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorAlex Wilson <alex.wilson@nokia.com>2012-02-14 13:25:26 +1000
committerQt by Nokia <qt-info@nokia.com>2012-02-15 02:35:37 +0100
commitc7d3f9be585b5aa4d0d53350a0a23f68ddd3c22f (patch)
treeeee64f5620f1eaa36cc1cd3f3e7f86da4bae5354 /src
parentbe0dfa34737a014e7ad060a90c4c24be9998fe13 (diff)
Produce unimplemented warning for QOpenGLBuffer::map only once
Change-Id: Ia4f136e964e4e0ca326f462b0996ef3d1b843cf6 Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
Diffstat (limited to 'src')
-rw-r--r--src/gui/opengl/qopenglbuffer.cpp12
1 files changed, 10 insertions, 2 deletions
diff --git a/src/gui/opengl/qopenglbuffer.cpp b/src/gui/opengl/qopenglbuffer.cpp
index e0ab98df21..e6879a9e60 100644
--- a/src/gui/opengl/qopenglbuffer.cpp
+++ b/src/gui/opengl/qopenglbuffer.cpp
@@ -529,7 +529,11 @@ void *QOpenGLBuffer::map(QOpenGLBuffer::Access access)
return glMapBufferARB(d->type, access);
#endif
Q_UNUSED(access);
- qWarning("QOpenGLBuffer::map(): pending implementation");
+ static bool warned = false;
+ if (!warned) {
+ qWarning("QOpenGLBuffer::map(): pending implementation");
+ warned = true;
+ }
return 0;
}
@@ -560,7 +564,11 @@ bool QOpenGLBuffer::unmap()
return false;
return glUnmapBufferARB(d->type) == GL_TRUE;
#endif
- qWarning("QOpenGLBuffer::map(): pending implementation");
+ static bool warned = false;
+ if (!warned) {
+ qWarning("QOpenGLBuffer::map(): pending implementation");
+ warned = true;
+ }
return 0;
}