diff --git a/plugins/vst_base/VstPlugin.cpp b/plugins/vst_base/VstPlugin.cpp index 64dc0b8299c..26c789275bb 100644 --- a/plugins/vst_base/VstPlugin.cpp +++ b/plugins/vst_base/VstPlugin.cpp @@ -34,9 +34,9 @@ #include #ifdef LMMS_BUILD_LINUX +# include # if QT_VERSION < 0x050000 # include -# include # else # include "X11EmbedContainer.h" # include @@ -62,6 +62,10 @@ #include "templates.h" #include "FileDialog.h" +#ifdef LMMS_BUILD_LINUX +# include +#endif + VstPlugin::VstPlugin( const QString & _plugin ) : m_plugin( _plugin ), @@ -324,16 +328,22 @@ bool VstPlugin::processMessage( const message & _m ) case IdVstPluginWindowID: m_pluginWindowID = _m.getInt(); -#ifdef LMMS_BUILD_WIN32 if( m_embedMethod == "none" ) { +#ifdef LMMS_BUILD_WIN32 // We're changing the owner, not the parent, // so this is legal despite MSDN's warning SetWindowLongPtr( (HWND)(intptr_t) m_pluginWindowID, GWLP_HWNDPARENT, (LONG_PTR) gui->mainWindow()->winId() ); - } #endif + +#ifdef LMMS_BUILD_LINUX + XSetTransientForHint( QX11Info::display(), + m_pluginWindowID, + gui->mainWindow()->winId() ); +#endif + } break; case IdVstPluginEditorGeometry: