mirror of
https://github.com/cookiengineer/audacity
synced 2025-11-21 08:27:13 +01:00
Menus.cpp no longer link dependent on top level menu definitions...
... They all use the registry. (This link dependency was not shown in diagrams generated by scripts/graph.pl, because it was not reflected in Menus.h but was done using extern declarations within Menus.cpp. That was a cheat, but it let all the other dependencies be exposed in the graph and mitigated first.)
This commit is contained in:
@@ -1278,10 +1278,11 @@ static CommandHandlerObject &findCommandHandler(AudacityProject &) {
|
||||
#define FN(X) (& TrackActions::Handler :: X)
|
||||
|
||||
// Under /MenuBar
|
||||
MenuTable::BaseItemSharedPtr TracksMenu()
|
||||
namespace {
|
||||
using namespace MenuTable;
|
||||
BaseItemSharedPtr TracksMenu()
|
||||
{
|
||||
// Tracks Menu (formerly Project Menu)
|
||||
using namespace MenuTable;
|
||||
using Options = CommandManager::Options;
|
||||
|
||||
static BaseItemSharedPtr menu{
|
||||
@@ -1437,10 +1438,15 @@ MenuTable::BaseItemSharedPtr TracksMenu()
|
||||
return menu;
|
||||
}
|
||||
|
||||
AttachedItem sAttachment1{
|
||||
wxT(""),
|
||||
Shared( TracksMenu() )
|
||||
};
|
||||
}
|
||||
|
||||
// Under /MenuBar/Optional/Extra
|
||||
MenuTable::BaseItemSharedPtr ExtraTrackMenu()
|
||||
{
|
||||
using namespace MenuTable;
|
||||
static BaseItemSharedPtr menu{
|
||||
( FinderScope{ findCommandHandler },
|
||||
Menu( wxT("Track"), XO("&Track"),
|
||||
|
||||
Reference in New Issue
Block a user