Browse Source

VST3 Host: Only call IPlugView::removed() if a previous call to attached() succeeded

v6.1.6
reuk 3 years ago
parent
commit
a3c55a967f
No known key found for this signature in database GPG Key ID: 9ADCD339CFC98A11
1 changed files with 10 additions and 3 deletions
  1. +10
    -3
      modules/juce_audio_processors/format_types/juce_VST3PluginFormat.cpp

+ 10
- 3
modules/juce_audio_processors/format_types/juce_VST3PluginFormat.cpp View File

@@ -1365,7 +1365,9 @@ struct VST3PluginWindow : public AudioProcessorEditor,
embeddedComponent.removeClient();
#endif
warnOnFailure (view->removed());
if (attachedCalled)
warnOnFailure (view->removed());
warnOnFailure (view->setFrame (nullptr));
processor.editorBeingDeleted (this);
@@ -1573,7 +1575,12 @@ private:
return;
}
warnOnFailure (view->attached ((void*) pluginHandle, defaultVST3WindowType));
const auto attachedResult = view->attached ((void*) pluginHandle, defaultVST3WindowType);
ignoreUnused (warnOnFailure (attachedResult));
if (attachedResult == kResultOk)
attachedCalled = true;
updatePluginScale();
}
}
@@ -1641,7 +1648,7 @@ private:
#endif
HandleFormat pluginHandle = {};
bool recursiveResize = false, isInOnSize = false;
bool recursiveResize = false, isInOnSize = false, attachedCalled = false;
ComponentPeer* currentPeer = nullptr;
Steinberg::IPlugViewContentScaleSupport* scaleInterface = nullptr;


Loading…
Cancel
Save