Plugin host window size issues

We have some problems setting the size of our host when hosting other plugins. When loading for example AUDistortion, we add the editor as a child component to our plugin host. The plugin host then resizes itself based on the plugin editor size. But it seems that the size of the plugin host is being constrained, resulting in the host window being too small to visualise the full plugin editor.

I’ve done some testing with the HostPluginDemo example and it has the same issue (JUCE 8.0.12).

To reproduce:

  • Run HostPluginDemo (Standalone)
  • Scan Audio Units
  • Select AUDistortion and click ‘Open in this plugin window’
  • You should now see that the host window is smaller than the plugin editor window, resulting in a clipped view

I noticed after the first call to resized() in the host window, a second call with smaller bounds is invoked by the OS through this method:

addMethod (NSViewComponentPeer::frameChangedSelector,   [] (id self, SEL, NSNotification*)   { callOnOwner (self, &NSViewComponentPeer::redirectMovedOrResized); });

This second call is what causing the host window to become smaller in size.

P.S.
I just found out this only exists in AUDistortion, it might only be a problem for this specific plugin?