From 0cab6cfe2f60662556c80576b291fab024a2c03a Mon Sep 17 00:00:00 2001 From: Alex May Date: Fri, 1 Mar 2024 08:42:14 +0000 Subject: [PATCH] Fixed a couple of Qt6 compile errors --- FugioApp/contextview.cpp | 4 ++-- include/fugio/app_helper.h | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/FugioApp/contextview.cpp b/FugioApp/contextview.cpp index 63e9b58e..3d3d0e37 100644 --- a/FugioApp/contextview.cpp +++ b/FugioApp/contextview.cpp @@ -473,7 +473,7 @@ void ContextView::loadContext( QSettings &pSettings, bool pPartial ) #if QT_VERSION < QT_VERSION_CHECK(6, 0, 0) QVariant::Type SrcType = PntSrc.type(); #else - QMetaType::Type SrcType = PntSrc.typeId(); + QMetaType::Type SrcType = static_cast( PntSrc.typeId() ); #endif if( SrcType == QMetaType::QPointF ) @@ -673,7 +673,7 @@ void ContextView::loadContext( QSettings &pSettings, bool pPartial ) #if QT_VERSION < QT_VERSION_CHECK(6, 0, 0) QVariant::Type PosType = pSettings.value( "position" ).type(); #else - QMetaType::Type PosType = pSettings.value( "position" ).typeId(); + QMetaType::Type PosType = static_cast( pSettings.value( "position" ).typeId() ); #endif if( PosType == QMetaType::QPointF ) diff --git a/include/fugio/app_helper.h b/include/fugio/app_helper.h index a52cfc94..ab526844 100644 --- a/include/fugio/app_helper.h +++ b/include/fugio/app_helper.h @@ -164,7 +164,7 @@ class AppHelper #if QT_VERSION < QT_VERSION_CHECK(6, 0, 0) const QString TranslationsPath = QLibraryInfo::location( QLibraryInfo::TranslationsPath ); #else - const QString TranslationsPath = QLibraryInfo::path( QLibraryInfo::TranslationsPath ) ); + const QString TranslationsPath = QLibraryInfo::path( QLibraryInfo::TranslationsPath ); #endif if( QFileInfo::exists( TranslationsPath ) )