From 542b15b851b78175575d5216a9420c88071a9fa9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Thorbj=C3=B8rn=20Lindeijer?= Date: Wed, 15 Jan 2025 14:11:46 +0100 Subject: [PATCH] Dropped workarounds for mingw49 (#4144) We no longer need to support this ancient version. --- src/libtiled/properties.h | 6 ------ src/plugins/yy/yyplugin.cpp | 3 +-- tests/properties/test_properties.cpp | 4 ++-- 3 files changed, 3 insertions(+), 10 deletions(-) diff --git a/src/libtiled/properties.h b/src/libtiled/properties.h index 404e7361f8..5928623048 100644 --- a/src/libtiled/properties.h +++ b/src/libtiled/properties.h @@ -49,12 +49,6 @@ class TILEDSHARED_EXPORT PropertyValue Q_PROPERTY(QString typeName READ typeName) public: - // needed to work around compilation issue with mingw49 - PropertyValue(const QVariant &value = QVariant(), int typeId = 0) - : value(value) - , typeId(typeId) - {} - QVariant value; int typeId; diff --git a/src/plugins/yy/yyplugin.cpp b/src/plugins/yy/yyplugin.cpp index 46435178f9..7c817593a5 100644 --- a/src/plugins/yy/yyplugin.cpp +++ b/src/plugins/yy/yyplugin.cpp @@ -1215,8 +1215,7 @@ static std::unique_ptr processImageLayer(const ImageLayer *imageLayer, gmrBackgroundLayer->animationSpeedType = optionalProperty(imageLayer, "animationSpeedType", gmrBackgroundLayer->animationSpeedType); gmrBackgroundLayer->userdefinedAnimFPS = imageLayer->resolvedProperty(QStringLiteral("animationFPS")).isValid(); - // Workaround compilation issue with mingw49 - return std::unique_ptr(std::move(gmrBackgroundLayer)); + return gmrBackgroundLayer; } static void processLayers(std::vector> &gmrLayers, diff --git a/tests/properties/test_properties.cpp b/tests/properties/test_properties.cpp index 08d359d9b4..b1f48378de 100644 --- a/tests/properties/test_properties.cpp +++ b/tests/properties/test_properties.cpp @@ -366,8 +366,8 @@ void test_Properties::enumWith31Flags() QVariant property1 = flagsAsString.toPropertyValue(QStringLiteral("1"), context); QVariant propertyAll = flagsAsString.toPropertyValue(allFlagsString, context); - QCOMPARE(property1, QVariant::fromValue(PropertyValue(1, flagsAsString.id))); - QCOMPARE(propertyAll, QVariant::fromValue(PropertyValue(allFlagsInt, flagsAsString.id))); + QCOMPARE(property1, QVariant::fromValue(PropertyValue { 1, flagsAsString.id })); + QCOMPARE(propertyAll, QVariant::fromValue(PropertyValue { allFlagsInt, flagsAsString.id })); ExportValue exportString1 = flagsAsString.toExportValue(property1.value().value, context); ExportValue exportStringAll = flagsAsString.toExportValue(propertyAll.value().value, context);