This follows a special case in PortGroupList::gather().
The Virtual Keyboard is an Ardour owned async terminal port,
that is in a session bundle (not a UserBundle).
See also 728d2a3771 and 559ffcff63
* Show Treeview again if it was hidden
* Hide heading(s) and table when no ports are available
* Fix memory leak, unmanaged OptionEditorHeading
* remove unused members
* Expose API via Public Editor
* Skip hidden tracks in calculation
* Use a single call to query playlist extents.
This way the playlist read-lock is needed at most once per track
which speeds up calculation.
This is in preparation to subscribe to playhead cursor position
changes in the recorder-UI.
This change also clean up the API, replacing a public variable
with a const access method and follows #12 of
https://ardour.org/styleguide.html
Apparently a user managed to remove a SC input and then
use the input's context-menu before the UI had caught up.
(PluginPinWidget::plugin_reconfigured happens during idle)
---
Exception Type: EXC_BAD_ACCESS (SIGSEGV)
Exception Codes: KERN_INVALID_ADDRESS at 0x0000000000000000
Thread 0 Crashed:: Dispatch queue: com.apple.main-thread
0 [..] PluginPinWidget::sc_input_press(_GdkEventButton*, boost::weak_ptr<ARDOUR::Port>) + 1140
AudioRegionView() c'tor calls create_waves() early on
before the _height is set [1].
Now one following can happen:
1. All peak-files are present. create_waves() directly calls
create_one_wave() for each channel. They are initialized
with zero height.
But all channels are present so waves[] is populated and
a later call to set_height() corrects this
2. All peak-files are still missing. create_waves() schedules
callbacks via PeaksReady -> peaks_ready_handler()
Those callbacks arrive after set_height() was called and
the waveforms are displayed correctly.
3. Only some peak-files are present. This can happen at
rec-stop when the region is created.
create_waves() directly calls create_one_wave() for available
peaks, and schedules peaks_ready_handler() for the remainder.
The directly created waves have zero-height.
Since not all waves are ready, they are stored in tmp_waves.
waves[] remains unpopulated.
The set_height() call only ever changed the height of wave[], which
resulted in hidden waveforms, until a user manually changed the
height of the track.
[1] the height is set from
```
#1 AudioStreamView::create_region_view(boost::shared_ptr<ARDOUR::Region>, bool, bool)
#2 AudioStreamView::add_region_view_internal(boost::shared_ptr<ARDOUR::Region>, bool, bool)
#3 StreamView::add_region_view(boost::weak_ptr<ARDOUR::Region>)
...
## PBD::Signal1 Playlist::RegionAdded()
```
We have to call close_view(), which calls IPlugView::removed()
before destroying the parent widget.
Previously ~VST3PluginUI() was called after the derived class
destroyed the owned private `_gui_widget`, `_ns_view` or x11 parent.
On windows that may lead to the hwnd of the window becoming invalid
before the call to ::removed().
VST3PluginInfo holds a shared_ptr reference to
VST3PluginModule. In order to cleanly unload a plugin, all
references have to be dropped.
Unloading a plugin cleanly before exit is needed in some
cases (e.g. Waves shell otherwise crashes)
Some fixed size AU, do unset `autoresizesSubviews` (Apple's default
is enabled). This also results in the initial size, and position
below Ardour's toolbar to be set incorrectly.
This fixes e.g. Reason Rack Plug AU (and maybe others).