mirror of
https://github.com/juce-framework/JUCE.git
synced 2026-01-10 23:44:24 +00:00
StandaloneFilterWindow: Auto-resize settings dialog when IO options change
This commit is contained in:
parent
04fdc4c209
commit
6832dca430
1 changed files with 18 additions and 0 deletions
|
|
@ -466,6 +466,24 @@ private:
|
|||
deviceSelector.setBounds (r);
|
||||
}
|
||||
|
||||
void childBoundsChanged (Component* childComp) override
|
||||
{
|
||||
if (childComp != &deviceSelector)
|
||||
return;
|
||||
|
||||
const auto extraHeight = [&]
|
||||
{
|
||||
if (! owner.getProcessorHasPotentialFeedbackLoop())
|
||||
return 0;
|
||||
|
||||
const auto itemHeight = deviceSelector.getItemHeight();
|
||||
const auto separatorHeight = (itemHeight >> 1);
|
||||
return itemHeight + separatorHeight;
|
||||
}();
|
||||
|
||||
setSize (getWidth(), deviceSelector.getHeight() + extraHeight);
|
||||
}
|
||||
|
||||
private:
|
||||
//==============================================================================
|
||||
StandalonePluginHolder& owner;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue