From 3726266e127c1f94ad64837c9dbe03d238255816 Mon Sep 17 00:00:00 2001 From: Hoang Bui <47828508+bongbui321@users.noreply.github.com> Date: Sun, 28 Jan 2024 14:40:28 -0500 Subject: [PATCH] Make creation of `Style` with empty URL possible (#107) * 5.12 enable * sanity check --- src/core/types.hpp | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/core/types.hpp b/src/core/types.hpp index fd346da..696fab1 100644 --- a/src/core/types.hpp +++ b/src/core/types.hpp @@ -42,9 +42,15 @@ struct Q_MAPLIBRE_CORE_EXPORT Style { CustomMap = 100 }; +#if QT_VERSION >= QT_VERSION_CHECK(5, 15, 0) explicit Style(QString url_, QString name_ = QString()) : url(std::move(url_)), name(std::move(name_)) {} +#else + explicit Style(QString url_ = QString(), QString name_ = QString()) + : url(std::move(url_)), + name(std::move(name_)) {} +#endif QString url; QString name;