summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorMarc Mutz <marc.mutz@kdab.com>2016-10-06 18:58:23 +0200
committerMarc Mutz <marc.mutz@kdab.com>2016-10-12 08:16:52 +0000
commit0c8b5b9a0446fdd881bbceddbbe2afc9ec9f1a0b (patch)
tree918fbfe6832f224d4012c2b23415475bec6dc141 /src
parenteade394e993bb190bb71152ea0bd805beade6f59 (diff)
QtOpenGl: compile with GCC 7
GCC 7 warns about implicit fall-throughs now. Fix by adding the missing comments. Change-Id: I081d4db07c7f2b30ee6344a166aaec34ac639ee5 Reviewed-by: Edward Welbourne <edward.welbourne@qt.io> Reviewed-by: Sean Harmer <sean.harmer@kdab.com>
Diffstat (limited to 'src')
-rw-r--r--src/opengl/qgl.cpp11
1 files changed, 11 insertions, 0 deletions
diff --git a/src/opengl/qgl.cpp b/src/opengl/qgl.cpp
index 652a498930..071c8d63cb 100644
--- a/src/opengl/qgl.cpp
+++ b/src/opengl/qgl.cpp
@@ -1287,14 +1287,19 @@ QGLFormat::OpenGLVersionFlags Q_AUTOTEST_EXPORT qOpenGLVersionFlagsFromString(co
switch (versionString[2].toLatin1()) {
case '5':
versionFlags |= QGLFormat::OpenGL_Version_1_5;
+ // fall through
case '4':
versionFlags |= QGLFormat::OpenGL_Version_1_4;
+ // fall through
case '3':
versionFlags |= QGLFormat::OpenGL_Version_1_3;
+ // fall through
case '2':
versionFlags |= QGLFormat::OpenGL_Version_1_2;
+ // fall through
case '1':
versionFlags |= QGLFormat::OpenGL_Version_1_1;
+ // fall through
default:
break;
}
@@ -1319,10 +1324,13 @@ QGLFormat::OpenGLVersionFlags Q_AUTOTEST_EXPORT qOpenGLVersionFlagsFromString(co
switch (versionString[2].toLatin1()) {
case '3':
versionFlags |= QGLFormat::OpenGL_Version_3_3;
+ // fall through
case '2':
versionFlags |= QGLFormat::OpenGL_Version_3_2;
+ // fall through
case '1':
versionFlags |= QGLFormat::OpenGL_Version_3_1;
+ // fall through
case '0':
break;
default:
@@ -1347,10 +1355,13 @@ QGLFormat::OpenGLVersionFlags Q_AUTOTEST_EXPORT qOpenGLVersionFlagsFromString(co
switch (versionString[2].toLatin1()) {
case '3':
versionFlags |= QGLFormat::OpenGL_Version_4_3;
+ // fall through
case '2':
versionFlags |= QGLFormat::OpenGL_Version_4_2;
+ // fall through
case '1':
versionFlags |= QGLFormat::OpenGL_Version_4_1;
+ // fall through
case '0':
break;
default: