summaryrefslogtreecommitdiffstats
path: root/src/opengl/qgl.cpp
diff options
context:
space:
mode:
authorRhys Weatherley <rhys.weatherley@nokia.com>2009-09-06 23:17:08 (GMT)
committerRhys Weatherley <rhys.weatherley@nokia.com>2009-09-06 23:17:08 (GMT)
commita470652c5ffadfa039dde48a88348e8314a6bc9a (patch)
tree0f32d5b6f65e162bb99638f88e6ccc6414209dad /src/opengl/qgl.cpp
parentd7bae8cd7684dd509fee56415f823b0c19b5d879 (diff)
downloadQt-a470652c5ffadfa039dde48a88348e8314a6bc9a.zip
Qt-a470652c5ffadfa039dde48a88348e8314a6bc9a.tar.gz
Qt-a470652c5ffadfa039dde48a88348e8314a6bc9a.tar.bz2
Update QGLFormat::operator== to include all fields.
The documentation says "Returns true if all the options of the two QGLFormats are equal", but that's not what it was doing. Reviewed-by: Sarah Smith
Diffstat (limited to 'src/opengl/qgl.cpp')
-rw-r--r--src/opengl/qgl.cpp7
1 files changed, 6 insertions, 1 deletions
diff --git a/src/opengl/qgl.cpp b/src/opengl/qgl.cpp
index dde4eba..ef07447 100644
--- a/src/opengl/qgl.cpp
+++ b/src/opengl/qgl.cpp
@@ -1256,7 +1256,12 @@ bool operator==(const QGLFormat& a, const QGLFormat& b)
{
return (int) a.d->opts == (int) b.d->opts && a.d->pln == b.d->pln && a.d->alphaSize == b.d->alphaSize
&& a.d->accumSize == b.d->accumSize && a.d->stencilSize == b.d->stencilSize
- && a.d->depthSize == b.d->depthSize;
+ && a.d->depthSize == b.d->depthSize
+ && a.d->redSize == b.d->redSize
+ && a.d->greenSize == b.d->greenSize
+ && a.d->blueSize == b.d->blueSize
+ && a.d->numSamples == b.d->numSamples
+ && a.d->swapInterval == b.d->swapInterval;
}