Two tiny fixes
1. If _pluginGui is null, don't ->create on it
2. Show the version if there's a plugin vs host version mismatch
@@ -117,8 +117,9 @@ bool PluginHost::load(const QString &path, int pluginIndex) {
}
if (!clap_version_is_compatible(desc->clap_version)) {
- qWarning() << "incompatible clap version: " << desc->clap_version.major << "."
- << desc->clap_version.minor << "." << desc->clap_version.revision;
+ qWarning() << "Incompatible clap version: Plugin is: " << desc->clap_version.major << "."
+ << desc->clap_version.minor << "." << desc->clap_version.revision
+ << " Host is " << CLAP_VERSION.major << "." << CLAP_VERSION.minor << "." << CLAP_VERSION.revision;
return false;
}
@@ -240,6 +241,9 @@ void PluginHost::setParentWindow(WId parentWindow) {
_isGuiVisible = false;
}
+ if (!_pluginGui)
+ return;
+
if (!_pluginGui->create(_plugin))
return;
