... The graph.pl script now makes nodes for header files that do not have
corresponding .cpp files.
With more nodes, more dependency cycles can be revealed that were not detected
before.
Two previously known cycles, and two newly revealed cycles, are broken up by
easy means (cutting and pasting of code to new files, changes of #include
directives) that don't involve more risky transformations.
extern declarations were also reviewed. extern declarations should not be in
.cpp files (at least for anything Audacity defines) but instead in .h files.
Definitions for those declarations should be in the corresponding .cpp files,
so that the graph generated by the script really shows all the link
dependencies.
To obey that rule requires supplying new .cpp files for existing .h files.
A similar rule applies for member funtions of classes.
So another large, hidden cycle was broken by defining PrefsPanel.cpp.
... Require the declarations to be in .h files, to be sure graph.pl detects the
dependencies.
Only one more #include was needed in Nyquist.cpp. This doesn't reveal any
more hidden cycles.
... in four cases; not in some other .cpp file.
This is another move that causes the generated graph to reflect dependencies
correctly.
This fixes other large, hidden cycles that involved PrefsDialog.cpp: there was
link dependency on that when PrefsPanel.h was used for the base class. No
longer.
Also cycles involving TrackPanel.cpp, which contained the default
implementations for TrackPanelCell and related abstract base classes.
... They are not necessary to build, but the do indicate some link
dependencies to fix, that were not shown in results of scripts/graph.pl.
The link dependencies exist because the header declaring some name did not
correspond to the .cpp file that defined it.
... Requires some more wx header inclusions, a renaming of CopyFile (to avoid
colliding with a certain macro changing it to CopyFileW), and an explicit
deletion of a copy constructor and assignment (to avoid generation of
std::vector members for an incomplete type)
This should catch any missing include directives. Windows
will have to come later as it needs a lot of work. It's
been using PCHs forever, so we've gotten away with a lot
of missing includes.
... It didn't really break the cycle, because there were still indirect
inclusions via AudacityHeaders.h.
This reverts commit 4f78874978975b42a5ca0ffb7175d586875da629.