Audacity  2.3.1
GetTrackInfoCommand.cpp
Go to the documentation of this file.
1 /**********************************************************************
2 
3  Audacity - A Digital Audio Editor
4  Copyright 1999-2009 Audacity Team
5  License: wxwidgets
6 
7  Dan Horgan
8  Marty Goddard
9 ******************************************************************//*******************************************************************/
18 
19 #include "../Audacity.h"
20 #include "GetTrackInfoCommand.h"
21 #include "../Project.h"
22 #include "../Track.h"
23 #include "../TrackPanel.h"
24 #include "../NoteTrack.h"
25 #include "../WaveTrack.h"
26 #include "../ShuttleGui.h"
27 #include "CommandContext.h"
28 
29 const int nTypes =3;
31 {
32  { XO("Tracks") },
33  { XO("Clips") },
34  { XO("Labels") },
35 };
36 
37 
39 {
40  mInfoType = 0;
41 }
42 
44  S.DefineEnum( mInfoType, wxT("Type"), 0, kTypes, nTypes );
45 
46  return true;
47 }
48 
50 {
51  auto types = LocalizedStrings( kTypes, nTypes );
52  S.AddSpace(0, 5);
53 
54  S.StartMultiColumn(2, wxALIGN_CENTER);
55  {
56  S.TieChoice( _("Types:"), mInfoType, &types);
57  }
58  S.EndMultiColumn();
59 }
60 
61 
62 
64 {
65  return false;
66 }
wxChoice * TieChoice(const wxString &Prompt, WrappedType &WrappedRef, const wxArrayString *pChoices)
Derived from ShuttleGuiBase, an Audacity specific class for shuttling data to and from GUI...
Definition: ShuttleGui.h:409
wxArrayString LocalizedStrings(const IdentInterfaceSymbol strings[], size_t nStrings)
Definition: Internat.cpp:303
bool DefineParams(ShuttleParams &S) override
void EndMultiColumn()
const int nTypes
#define XO(s)
Definition: Internat.h:33
CommandContext provides addiitonal information to an 'Apply()' command. It provides the project...
Shuttle that deals with parameters. This is a base class with lots of virtual functions that do nothi...
Definition: Shuttle.h:60
kTypes
Definition: Noise.cpp:30
virtual void DefineEnum(int &var, const wxChar *key, const int vdefault, const IdentInterfaceSymbol strings[], size_t nStrings)
Definition: Shuttle.cpp:345
void StartMultiColumn(int nCols, int PositionFlags=wxALIGN_LEFT)
void PopulateOrExchange(ShuttleGui &S) override
IdentInterfaceSymbol pairs a persistent string identifier used internally with an optional...
_("Move Track &Down")+wxT("\t")+(GetActiveProject() -> GetCommandManager() ->GetKeyFromName(wxT("TrackMoveDown")).Raw()), OnMoveTrack) POPUP_MENU_ITEM(OnMoveTopID, _("Move Track to &Top")+wxT("\t")+(GetActiveProject() ->GetCommandManager() ->GetKeyFromName(wxT("TrackMoveTop")).Raw()), OnMoveTrack) POPUP_MENU_ITEM(OnMoveBottomID, _("Move Track to &Bottom")+wxT("\t")+(GetActiveProject() ->GetCommandManager() ->GetKeyFromName(wxT("TrackMoveBottom")).Raw()), OnMoveTrack)#define SET_TRACK_NAME_PLUGIN_SYMBOLclass SetTrackNameCommand:public AudacityCommand
wxSizerItem * AddSpace(int width, int height)
Declarations of GetTrackInfoCommand and GetTrackInfoCommandType classes.
virtual bool Apply()