diff --git a/qt6-after/qt6-migrated-legatus/Lts/Common/LtsWidgets/lts_base.h b/qt6-after/qt6-migrated-legatus/Lts/Common/LtsWidgets/lts_base.h index 764fdff9d..0296f6e3f 100644 --- a/qt6-after/qt6-migrated-legatus/Lts/Common/LtsWidgets/lts_base.h +++ b/qt6-after/qt6-migrated-legatus/Lts/Common/LtsWidgets/lts_base.h @@ -16,8 +16,10 @@ #include #include #include -#include #include +#if QT_VERSION < QT_VERSION_CHECK(6, 0, 0) +#include +#endif #include @@ -80,6 +82,7 @@ inline void addTouchScroll(QWidget *widget) { if (!widget) return; +#if QT_VERSION < QT_VERSION_CHECK(6, 0, 0) widget->setAttribute(Qt::WA_AcceptTouchEvents); { @@ -101,6 +104,10 @@ inline void addTouchScroll(QWidget *widget) return; } } +#else + // Qt6: Touch scrolling is enabled by default for scrollable widgets + Q_UNUSED(widget) +#endif } enum class ButtonSize