diff --git a/CMakeLists.txt b/CMakeLists.txt index 6c88567..74bc49b 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -151,7 +151,9 @@ elseif (QT_PACKAGE_PREFIX MATCHES ".*Qt([0-9]+).*") endif () # require Qt 6 for the Qt Quick GUI -if (QUICK_GUI AND MAJOR_QT_VERSION VERSION_LESS 6 OR MAJOR_QT_VERSION VERSION_GREATER_EQUAL 7) +if (QUICK_GUI + AND MAJOR_QT_VERSION VERSION_LESS 6 + OR MAJOR_QT_VERSION VERSION_GREATER_EQUAL 7) message(FATAL_ERROR "The Qt Quick GUI is only compatible with Qt 6 (but Qt ${MAJOR_QT_VERSION} was found).") endif () diff --git a/model/fieldmodel.cpp b/model/fieldmodel.cpp index a7584c6..e8a66e6 100644 --- a/model/fieldmodel.cpp +++ b/model/fieldmodel.cpp @@ -340,7 +340,8 @@ bool FieldModel::moveRows(const QModelIndex &sourceParent, int sourceRow, int co // begin the move // note: When moving rows down (destinationChild > sourceRow) the third param is still counted in the initial array! - if (!beginMoveRows(sourceParent, sourceRow, sourceRow + count - 1, destinationParent, destinationChild > sourceRow ? destinationChild + count : destinationChild)) { + if (!beginMoveRows(sourceParent, sourceRow, sourceRow + count - 1, destinationParent, + destinationChild > sourceRow ? destinationChild + count : destinationChild)) { return false; }