summaryrefslogtreecommitdiffstats
path: root/src/gui/image/qimagewriter.cpp
diff options
context:
space:
mode:
authorPoul Sysolyatin <psytonx@gmail.com>2013-01-21 14:00:07 +0700
committerThe Qt Project <gerrit-noreply@qt-project.org>2013-01-29 09:28:19 +0100
commit9d432881804edc3f680de610e40b669f97df6f9b (patch)
treea4c87d8c0254d0cd2deae0e6751051124e8db030 /src/gui/image/qimagewriter.cpp
parent8995453263721507a4c923b905f50f800010d9ad (diff)
Exclude BMP from supported formats if it disabled by Qt build
If Qt build without BMP support, we need exclude this format from output of QImageWriter::supportedImageFormats() and QImageReader::supportedImageFormats() methods. Task-number: QTBUG-27028 Change-Id: I44e8956247066c0836b1ff7bf9a1f356fe568af1 Reviewed-by: Gunnar Sletta <gunnar.sletta@digia.com>
Diffstat (limited to 'src/gui/image/qimagewriter.cpp')
-rw-r--r--src/gui/image/qimagewriter.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/gui/image/qimagewriter.cpp b/src/gui/image/qimagewriter.cpp
index 8e0f3fdcf0..20e601be03 100644
--- a/src/gui/image/qimagewriter.cpp
+++ b/src/gui/image/qimagewriter.cpp
@@ -708,7 +708,9 @@ void supportedImageHandlerFormats(QFactoryLoader *loader,
QList<QByteArray> QImageWriter::supportedImageFormats()
{
QSet<QByteArray> formats;
+#ifndef QT_NO_IMAGEFORMAT_BMP
formats << "bmp";
+#endif
#ifndef QT_NO_IMAGEFORMAT_PPM
formats << "pbm" << "pgm" << "ppm";
#endif