Skip to content

Commit

Permalink
Dropped workarounds for mingw49 (#4144)
Browse files Browse the repository at this point in the history
We no longer need to support this ancient version.
  • Loading branch information
bjorn authored Jan 15, 2025
1 parent 76e4f61 commit 542b15b
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 10 deletions.
6 changes: 0 additions & 6 deletions src/libtiled/properties.h
Original file line number Diff line number Diff line change
Expand Up @@ -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;

Expand Down
3 changes: 1 addition & 2 deletions src/plugins/yy/yyplugin.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1215,8 +1215,7 @@ static std::unique_ptr<GMRLayer> 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<GMRLayer>(std::move(gmrBackgroundLayer));
return gmrBackgroundLayer;
}

static void processLayers(std::vector<std::unique_ptr<GMRLayer>> &gmrLayers,
Expand Down
4 changes: 2 additions & 2 deletions tests/properties/test_properties.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -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<PropertyValue>().value, context);
ExportValue exportStringAll = flagsAsString.toExportValue(propertyAll.value<PropertyValue>().value, context);
Expand Down

0 comments on commit 542b15b

Please sign in to comment.