summaryrefslogtreecommitdiffstats
path: root/src/gui
diff options
context:
space:
mode:
authorSergio Ahumada <sergio.ahumada@digia.com>2012-10-27 16:45:32 +0200
committerThe Qt Project <gerrit-noreply@qt-project.org>2012-10-29 13:51:10 +0100
commit914e1f360868e844577dd98a179a7c8bc37bf272 (patch)
tree582a9345844ed2c7819846b6ee2070da4ec6478d /src/gui
parente880ff9cae5cfd215a9fea0bce27a8f3d2d227b0 (diff)
Remove some dead code in switch statements
Following the Code Style described in http://qt-project.org/wiki/Qt_Coding_Style#e289ee44592e9c32d4212069f0806daf There is no need for a 'break' after a 'return'. Change-Id: I1eca350391a7e4e14e504d60b24b69982cc5ac47 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Diffstat (limited to 'src/gui')
-rw-r--r--src/gui/image/qimage.cpp10
-rw-r--r--src/gui/opengl/qopenglframebufferobject.cpp1
-rw-r--r--src/gui/painting/qpathclipper.cpp1
3 files changed, 0 insertions, 12 deletions
diff --git a/src/gui/image/qimage.cpp b/src/gui/image/qimage.cpp
index 25999b7d06..9da360bc26 100644
--- a/src/gui/image/qimage.cpp
+++ b/src/gui/image/qimage.cpp
@@ -4915,43 +4915,33 @@ int QImage::metric(PaintDeviceMetric metric) const
switch (metric) {
case PdmWidth:
return d->width;
- break;
case PdmHeight:
return d->height;
- break;
case PdmWidthMM:
return qRound(d->width * 1000 / d->dpmx);
- break;
case PdmHeightMM:
return qRound(d->height * 1000 / d->dpmy);
- break;
case PdmNumColors:
return d->colortable.size();
- break;
case PdmDepth:
return d->depth;
- break;
case PdmDpiX:
return qRound(d->dpmx * 0.0254);
- break;
case PdmDpiY:
return qRound(d->dpmy * 0.0254);
- break;
case PdmPhysicalDpiX:
return qRound(d->dpmx * 0.0254);
- break;
case PdmPhysicalDpiY:
return qRound(d->dpmy * 0.0254);
- break;
default:
qWarning("QImage::metric(): Unhandled metric type %d", metric);
diff --git a/src/gui/opengl/qopenglframebufferobject.cpp b/src/gui/opengl/qopenglframebufferobject.cpp
index ef8e420c27..380ada37e0 100644
--- a/src/gui/opengl/qopenglframebufferobject.cpp
+++ b/src/gui/opengl/qopenglframebufferobject.cpp
@@ -349,7 +349,6 @@ bool QOpenGLFramebufferObjectPrivate::checkFramebufferStatus(QOpenGLContext *ctx
case GL_NO_ERROR:
case GL_FRAMEBUFFER_COMPLETE:
return true;
- break;
case GL_FRAMEBUFFER_UNSUPPORTED:
qDebug("QOpenGLFramebufferObject: Unsupported framebuffer format.");
break;
diff --git a/src/gui/painting/qpathclipper.cpp b/src/gui/painting/qpathclipper.cpp
index 8cf57a8987..4b53257832 100644
--- a/src/gui/painting/qpathclipper.cpp
+++ b/src/gui/painting/qpathclipper.cpp
@@ -1630,7 +1630,6 @@ QPainterPath QPathClipper::clip(Operation operation)
result.addRect(subjectBounds);
return result;
}
- break;
case BoolAnd:
return clipPath;
case BoolOr: