!!! THERE WILL NO DOUBT BE BUGS !!!
This is a big one and there's still several things to
complete. Just want to get this in the wild to start
receiving feedback.
One big thing right now is that it will NOT load pre-aup3
files. An importer is on the way for that.
This removes all of the OnDemand code embedded throughout
the main codebase. Individual files related specifically
to OD have been left in place, but removed from the build.
... without making undesirable dependency cycles.
Eliminate calls to NewWaveTrack in effects, but in Edit>Copy too, which was
not mentioned in the bug report. (Copying a track, deselecting all, and pasting
preserved CLIP colors, but not the TRACK color setting which applies to newly
generated clips.)
Instead, always use the new function WaveTrack::EmptyCopy from the track to be
later replaced, getting color information.
NewWaveTrack is still used in benchmark test, import, the Track menu
commands that make new tracks, recording to new tracks, and generators without
a selection, where there is no track to copy from.
Also when deserializing tracks from the .aup file, in which case the saved
color is later retrieved from the file.
Also, in mix-and-render, where other logic decides whether to copy colors
afterward.
See commit a9658e6ef7
... because we undo the move,
"Demote vertical zooming code into WaveTrack.cpp ..." done at 1f4bf26
That was done so that WaveTrack would not depend on WaveTrackVZoomHandle, but
made it instead depend on ProjectHistory, which is undesirable.
But since then, commit 3797a52 moved the special minimizing code for WaveTrack
into WaveTrackView.
... non-intrusively in the Track suclasses, registering functions instead.
For each abstract factory function (of two), build a table of concrete factory
functions, paralleling the hierarchy of Track subclesses. Dispatch using
runt time type information in the Track objects.
... And Track no longer inherits TrackPanelCell, so be careful to rewrite
some dynamic_casts too to check instead for TrackView. Those casts won't fail
to recompile if not rewritten.
... in anticipation of making views to tracks many-to-one, but then the rulers
should be one-to-one with the views. So go through the view to get the ruler.
The ruler is really a left-hand extension for each view.
... generalizing the fix of commit 7591891 to other cases, making the iterators
safe for adaptation with std::reverse_iterator should the need ever arise
... except Audacity.h; and in no others.
Do so even if Experimental.h gets multiply included, as in both the .h and
.cpp files.
This makes it easier to do a text scan to be sure there are no unintended quiet
changes of meaning because of omission of Experimental.h when the flag is
an enabled one.
Also move inclusions of Experimental.h earlier.
Also don't require Experimental.h to be preceded by Audacity.h to define
EXPERIMENTAL_MIDI_OUT correctly.
... so that we can use Track::SharedPointer without undefined behavior even on
tracks that don't yet belong to any TrackList.
Also fix the return type of function template TrackList::Add and remove some
casts.
... for wxString and wxArrayStringEx, holding file paths (absolute or relative,
directory or plain file); to be replaced later with different types
(not yet using std::vector, becase of some uses of wxArrayString::Index with
two arguments)
Rather than 'cut' (i.e. drop, not cut as in 'cut preview') channels immediately, we now only do so
if their last gain was already 0.0. Instead they micro-fade out. Later when the channels come back,
their last gain will be 0.0, so they will micro-fade in.
A comment explains that the code would be cleaner if we just computed gains, and not whether to
drop channels.