diff options
author | Alex Wilson <alex.wilson@nokia.com> | 2012-02-14 13:25:26 +1000 |
---|---|---|
committer | Qt by Nokia <qt-info@nokia.com> | 2012-02-15 02:35:37 +0100 |
commit | c7d3f9be585b5aa4d0d53350a0a23f68ddd3c22f (patch) | |
tree | eee64f5620f1eaa36cc1cd3f3e7f86da4bae5354 /src/gui/opengl/qopenglbuffer.cpp | |
parent | be0dfa34737a014e7ad060a90c4c24be9998fe13 (diff) | |
download | qtbase-c7d3f9be585b5aa4d0d53350a0a23f68ddd3c22f.tar.gz |
Produce unimplemented warning for QOpenGLBuffer::map only once
Change-Id: Ia4f136e964e4e0ca326f462b0996ef3d1b843cf6
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
Diffstat (limited to 'src/gui/opengl/qopenglbuffer.cpp')
-rw-r--r-- | src/gui/opengl/qopenglbuffer.cpp | 12 |
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; } |