1
0
Fork 0
mirror of https://github.com/juce-framework/JUCE.git synced 2026-01-14 00:14:18 +00:00

macOS: Always resize embedded NSView asynchronously in AutoResizingNSViewComponent to fix a bug with some AU plug-ins reporting the incorrect size

This commit is contained in:
ed 2018-11-27 11:24:15 +00:00
parent ceec72457d
commit 1bea6b517d

View file

@ -93,23 +93,8 @@ static inline bool arrayContainsPlugin (const OwnedArray<PluginDescription>& lis
struct AutoResizingNSViewComponent : public ViewComponentBaseClass,
private AsyncUpdater
{
void childBoundsChanged (Component*) override
{
if (recursive)
{
triggerAsyncUpdate();
}
else
{
recursive = true;
resizeToFitView();
recursive = false;
}
}
void handleAsyncUpdate() override { resizeToFitView(); }
bool recursive = false;
void childBoundsChanged (Component*) override { triggerAsyncUpdate(); }
void handleAsyncUpdate() override { resizeToFitView(); }
};
//==============================================================================