From 2501c6169d1fce7f3b369ebb6f784bb767af9e9f Mon Sep 17 00:00:00 2001 From: Michail Vourlakos Date: Wed, 4 Dec 2019 23:01:44 +0200 Subject: [PATCH] fix compatibility with qt>=5.14 --fix qml register type for deprecated code reference --- app/lattecorona.cpp | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/app/lattecorona.cpp b/app/lattecorona.cpp index 78b3a6ded..bc89c8185 100644 --- a/app/lattecorona.cpp +++ b/app/lattecorona.cpp @@ -1106,6 +1106,7 @@ void Corona::setBroadcastedBackgroundsEnabled(QString activity, QString screenNa inline void Corona::qmlRegisterTypes() const { +#if QT_VERSION < QT_VERSION_CHECK(5, 14, 0) qmlRegisterType(); qmlRegisterType(); qmlRegisterType(); @@ -1113,6 +1114,15 @@ inline void Corona::qmlRegisterTypes() const qmlRegisterType(); qmlRegisterType(); qmlRegisterType(); +#else + qmlRegisterAnonymousType("latte-dock", 1); + qmlRegisterAnonymousType("latte-dock", 1); + qmlRegisterAnonymousType("latte-dock", 1); + qmlRegisterAnonymousType("latte-dock", 1); + qmlRegisterAnonymousType("latte-dock", 1); + qmlRegisterAnonymousType("latte-dock", 1); + qmlRegisterAnonymousType("latte-dock", 1); +#endif } }