Don't clear the processor box selection when leaving for
a non-linearly related widget/window (e.g. a context menu)
Note that the deselect is a little buggy but that was
true before the referenced commit too. If you move the mouse too
fast out of a processor box, then depending on where the
mouse stops, no leave notify message is sent
In case there are any unconnected tracks, the track's output is
assumed to align to the master bus (see Route::update_signal_latency).
For this to work correctly the master bus port's public latency
has to be set first.
This fixes e.g. the following issue: add a latent plugin to
the monitor section. Then toggle its bypass or remove it.
Previously the worst-case latency remained unchanged.
Bindings were not loaded until after ProcessorBoxen were created,
meaning they had no effect (the ProcessorBoxen set their ardour
bindings to null).
Also handle leave-means-deselect at ProcessorBox level rather than
MixerStrip level, to include MonitorSection PB
VST3PI::performEdit already updates the shadow data, so
since 979f9876a7
VST3Plugin::set_parameter effectively did nothing (unless a user
rapidly moves the control slider, in which case the next process
cycle sets a previous value).
We now use the same actions in all modes, and the logic is:
1. is there a selected mixer strip and are we in it: if so, delete selected
processors
2. are we in draw or internal mode? if so ..
2a. if there are selected control points, delete them
2b. if not, attempt to delete MIDI notes
2c. done
3. continue with delete operation as before
~Session calls AudioEngine::remove_session(), which fades out,
then unsets the session, and then in libs/ardour/audioengine.cc:460
```
session_removed.signal(); // wakes up thread that initiated session removal
```
Session d'tor continues, and calls Port::PortDrop(), which
unregisters all ports one at a time.
Concurrently, AudioEngine continues, and calls PortManager::silence_outputs
which gets all ports first (!), and then iterates over them.
There is a race condition which can lead to
DummyAudioBackend::get_buffer: Assertion `valid_port (port)' failed
This fixes a "too many sections" issue
```
Fatal error: can't write 159 bytes to section .text of build/libs/ardour/luabindings.cc.1.o: 'file too big'
x86_64-w64-mingw32-as: build/libs/ardour/luabindings.cc.1.o: too many sections (36781)
```
This also mitigates an issue that selecting a track in
a group may select other tracks. Previously the last
selected track's input was connected to MIDI ports, which
is usually not the track that the user clicked on.