diff --git a/skins/material/QskMaterialSkin.cpp b/skins/material/QskMaterialSkin.cpp index 03b170ba..e496a556 100644 --- a/skins/material/QskMaterialSkin.cpp +++ b/skins/material/QskMaterialSkin.cpp @@ -237,8 +237,7 @@ void Editor::setupMenu() setGradient( Q::Panel, m_pal.baseColor ); - const bool isCascading = qskMaybeDesktopPlatform(); - setFlagHint( Q::Panel | A::Style, isCascading ); + setFlagHint( Q::Panel | A::Style, false ); // not cascading #if 0 setPadding( Q::Separator, QMarginsF( 10, 0, 10, 0 ) ); diff --git a/src/common/QskPlatform.cpp b/src/common/QskPlatform.cpp index 67fbfdf1..e94f9b57 100644 --- a/src/common/QskPlatform.cpp +++ b/src/common/QskPlatform.cpp @@ -42,16 +42,10 @@ const QPlatformIntegration* qskPlatformIntegration() bool qskMaybeDesktopPlatform() { - // this is what QC2 is doing for menus ? - -#if QT_VERSION >= QT_VERSION_CHECK( 5, 15, 0 ) -#if !QT_CONFIG(cursor) - return false; -#endif -#endif - +#if QT_CONFIG(cursor) if ( const auto platform = QGuiApplicationPrivate::platformIntegration() ) return platform->hasCapability( QPlatformIntegration::MultipleWindows ); +#endif return false; } diff --git a/src/controls/QskMenu.cpp b/src/controls/QskMenu.cpp index 9c1389f9..249765e4 100644 --- a/src/controls/QskMenu.cpp +++ b/src/controls/QskMenu.cpp @@ -6,6 +6,7 @@ #include #include #include +#include #include #include @@ -85,7 +86,7 @@ QskMenu::~QskMenu() // has no effect as we do not offer submenus yet. TODO ... bool QskMenu::isCascading() const { - return flagHint( QskMenu::Panel | QskAspect::Style ); + return flagHint( QskMenu::Panel | QskAspect::Style, qskMaybeDesktopPlatform() ); } void QskMenu::setCascading( bool on )