summaryrefslogtreecommitdiffstats
path: root/src/plugins/imageformats/dds
diff options
context:
space:
mode:
authorSona Kurazyan <sona.kurazyan@qt.io>2019-07-05 16:49:01 +0200
committerSona Kurazyan <sona.kurazyan@qt.io>2019-07-08 09:58:59 +0200
commit7ad0ef0f31afd89509dc2cb3c102b22c0e6c725c (patch)
tree3e9d844b87eda4c723519aecad7206ffe546db39 /src/plugins/imageformats/dds
parentd2c5409c1a4994052fd0c470148f1cd38f908d1c (diff)
Fix compilation with disabled deprecated APIs
The QImageIOHandler::name() has been deprecated since 5.13, but its overrides weren't. Enabled compilation of the overrides only when the QImageIOHandler::name() is compiled. Task-number: QTBUG-76491 Change-Id: I913f03f730969ea88864a5a08afe50c4eac533ca Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
Diffstat (limited to 'src/plugins/imageformats/dds')
-rw-r--r--src/plugins/imageformats/dds/qddshandler.cpp2
-rw-r--r--src/plugins/imageformats/dds/qddshandler.h2
2 files changed, 4 insertions, 0 deletions
diff --git a/src/plugins/imageformats/dds/qddshandler.cpp b/src/plugins/imageformats/dds/qddshandler.cpp
index 3a44b51..845f9b3 100644
--- a/src/plugins/imageformats/dds/qddshandler.cpp
+++ b/src/plugins/imageformats/dds/qddshandler.cpp
@@ -1382,10 +1382,12 @@ QDDSHandler::QDDSHandler() :
{
}
+#if QT_DEPRECATED_SINCE(5, 13)
QByteArray QDDSHandler::name() const
{
return QByteArrayLiteral("dds");
}
+#endif
bool QDDSHandler::canRead() const
{
diff --git a/src/plugins/imageformats/dds/qddshandler.h b/src/plugins/imageformats/dds/qddshandler.h
index 665bd16..f4bc888 100644
--- a/src/plugins/imageformats/dds/qddshandler.h
+++ b/src/plugins/imageformats/dds/qddshandler.h
@@ -53,7 +53,9 @@ class QDDSHandler : public QImageIOHandler
public:
QDDSHandler();
+#if QT_DEPRECATED_SINCE(5, 13)
QByteArray name() const override;
+#endif
bool canRead() const override;
bool read(QImage *image) override;