Audacity 3.2.0
Functions | Variables
CommonCommandFlags.cpp File Reference
#include "CommonCommandFlags.h"
#include <wx/frame.h>
#include "AudioIO.h"
#include "Clipboard.h"
#include "LabelTrack.h"
#include "Project.h"
#include "ProjectAudioIO.h"
#include "ProjectHistory.h"
#include "ProjectWindows.h"
#include "SyncLock.h"
#include "UndoManager.h"
#include "ViewInfo.h"
#include "WaveTrack.h"
#include "commands/CommandManagerWindowClasses.h"
Include dependency graph for CommonCommandFlags.cpp:

Go to the source code of this file.

Functions

bool EditableTracksSelectedPred (const AudacityProject &project)
 
bool AnyTracksSelectedPred (const AudacityProject &project)
 
bool AudioIOBusyPred (const AudacityProject &project)
 
bool TimeSelectedPred (const AudacityProject &project)
 
const CommandFlagOptionscutCopyOptions ()
 
const ReservedCommandFlagAudioIONotBusyFlag ()
 
const ReservedCommandFlagStereoRequiredFlag ()
 
const ReservedCommandFlagNoiseReductionTimeSelectedFlag ()
 
const ReservedCommandFlagTimeSelectedFlag ()
 
const ReservedCommandFlagWaveTracksSelectedFlag ()
 
const ReservedCommandFlagTracksExistFlag ()
 
const ReservedCommandFlagEditableTracksSelectedFlag ()
 
const ReservedCommandFlagAnyTracksSelectedFlag ()
 
const ReservedCommandFlagTrackPanelHasFocus ()
 
const ReservedCommandFlagAudioIOBusyFlag ()
 
const ReservedCommandFlagCaptureNotBusyFlag ()
 
const ReservedCommandFlagLabelTracksExistFlag ()
 
const ReservedCommandFlagUndoAvailableFlag ()
 
const ReservedCommandFlagRedoAvailableFlag ()
 
const ReservedCommandFlagZoomInAvailableFlag ()
 
const ReservedCommandFlagZoomOutAvailableFlag ()
 
const ReservedCommandFlagWaveTracksExistFlag ()
 
const ReservedCommandFlagIsNotSyncLockedFlag ()
 
const ReservedCommandFlagIsSyncLockedFlag ()
 
const ReservedCommandFlagNotMinimizedFlag ()
 
const ReservedCommandFlagPausedFlag ()
 
const ReservedCommandFlagNoAutoSelect ()
 

Variables

const CommandFlagOptions noiseReductionOptions
 

Function Documentation

◆ AnyTracksSelectedFlag()

const ReservedCommandFlag & AnyTracksSelectedFlag ( )

Definition at line 179 of file CommonCommandFlags.cpp.

179 { static ReservedCommandFlag flag{
181 { []( const TranslatableString &Name ){ return
182 // i18n-hint: %s will be replaced by the name of an action, such as "Remove Tracks".
183 XO("\"%s\" requires one or more tracks to be selected.").Format( Name );
184 },"Audacity_Selection" }
185 }; return flag; }
bool AnyTracksSelectedPred(const AudacityProject &project)
XO("Cut/Copy/Paste")
static std::once_flag flag
Holds a msgid for the translation catalog; may also bind format arguments.

References AnyTracksSelectedPred(), flag, and XO().

Referenced by anonymous_namespace{TrackMenus.cpp}::TracksMenu().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ AnyTracksSelectedPred()

bool AnyTracksSelectedPred ( const AudacityProject project)

Definition at line 54 of file CommonCommandFlags.cpp.

55{
56 auto range = TrackList::Get(project).Selected();
57 return !range.empty();
58};
const auto project
static TrackList & Get(AudacityProject &project)
Definition: Track.cpp:314
auto Selected() -> TrackIterRange< TrackType >
Definition: Track.h:967

References TrackList::Get(), project, and TrackList::Selected().

Referenced by AnyTracksSelectedFlag().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ AudioIOBusyFlag()

const ReservedCommandFlag & AudioIOBusyFlag ( )

Definition at line 199 of file CommonCommandFlags.cpp.

199 { static ReservedCommandFlag flag{
202 }; return flag; } //lll
bool AudioIOBusyPred(const AudacityProject &project)
CommandFlagOptions && QuickTest() &&
Definition: CommandFlag.h:51

References AudioIOBusyPred(), flag, and CommandFlagOptions::QuickTest().

Referenced by anonymous_namespace{SelectMenus.cpp}::ExtraSeekMenu(), anonymous_namespace{TransportMenus.cpp}::ExtraTransportMenu(), and anonymous_namespace{LabelMenus.cpp}::LabelEditMenus().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ AudioIOBusyPred()

bool AudioIOBusyPred ( const AudacityProject project)

Definition at line 60 of file CommonCommandFlags.cpp.

61{
63 ProjectAudioIO::Get( project ).GetAudioIOToken());
64};
static AudioIOBase * Get()
Definition: AudioIOBase.cpp:94
bool IsAudioTokenActive(int token) const
Returns true if the stream is active, or even if audio I/O is busy cleaning up its data or writing to...
static ProjectAudioIO & Get(AudacityProject &project)

References AudioIOBase::Get(), ProjectAudioIO::Get(), AudioIOBase::IsAudioTokenActive(), and project.

Referenced by AudioIOBusyFlag(), AudioIONotBusyFlag(), and anonymous_namespace{EditMenus.cpp}::JoinClipsAvailableFlag().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ AudioIONotBusyFlag()

const ReservedCommandFlag & AudioIONotBusyFlag ( )

Definition at line 118 of file CommonCommandFlags.cpp.

118 { static ReservedCommandFlag flag{
119 [](const AudacityProject &project ){
120 return !AudioIOBusyPred( project );
121 },
122 CommandFlagOptions{ []( const TranslatableString& ) { return
123 // This reason will not be shown, because options that require it will be greyed out.
124 XO("You can only do this when playing and recording are\nstopped. (Pausing is not sufficient.)");
125 } ,"FAQ:Errors:Audio Must Be Stopped"}
126 .QuickTest()
127 .Priority( 1 )
128 }; return flag; }//lll
The top-level handle to an Audacity project. It serves as a source of events that other objects can b...
Definition: Project.h:90

References AudioIOBusyPred(), flag, project, and XO().

Referenced by anonymous_namespace{PluginMenus.cpp}::AnalyzeMenu(), anonymous_namespace{SelectMenus.cpp}::CursorMenu(), ProjectAudioManager::DoRecord(), anonymous_namespace{EditMenus.cpp}::EditMenu(), anonymous_namespace{PluginMenus.cpp}::EffectMenu(), anonymous_namespace{DeviceToolBar.cpp}::ExtraDeviceMenu(), anonymous_namespace{EditMenus.cpp}::ExtraEditMenu(), anonymous_namespace{FileMenus.cpp}::ExtraExportMenu(), anonymous_namespace{TrackMenus.cpp}::ExtraTrackMenu(), anonymous_namespace{TransportMenus.cpp}::ExtraTransportMenu(), anonymous_namespace{FileMenus.cpp}::FileMenu(), anonymous_namespace{PluginMenus.cpp}::GenerateMenu(), anonymous_namespace{HelpMenus.cpp}::HelpMenu(), anonymous_namespace{LabelMenus.cpp}::LabelEditMenus(), PluginMenuItems(), DEFINE_VERSION_CHECK::RegisterMenuItems(), anonymous_namespace{NyqBench.cpp}::RegisterMenuItems(), anonymous_namespace{PluginMenus.cpp}::ToolsMenu(), anonymous_namespace{TrackMenus.cpp}::TracksMenu(), and anonymous_namespace{TransportMenus.cpp}::TransportMenu().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ CaptureNotBusyFlag()

const ReservedCommandFlag & CaptureNotBusyFlag ( )

Definition at line 204 of file CommonCommandFlags.cpp.

204 { static ReservedCommandFlag flag{
205 [](const AudacityProject &){
206 auto gAudioIO = AudioIO::Get();
207 return !(
208 gAudioIO->IsBusy() &&
209 gAudioIO->GetNumCaptureChannels() > 0
210 );
211 }
212 }; return flag; };
static AudioIO * Get()
Definition: AudioIO.cpp:126

References flag, and AudioIO::Get().

Referenced by anonymous_namespace{TranscriptionToolBar.cpp}::ExtraPlayAtSpeedItems(), anonymous_namespace{TransportMenus.cpp}::ExtraSelectionItems(), anonymous_namespace{TransportMenus.cpp}::ExtraTransportMenu(), anonymous_namespace{Scrubbing.cpp}::KeyboardScrubbingItems(), and anonymous_namespace{Scrubbing.cpp}::menuItems().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ cutCopyOptions()

const CommandFlagOptions & cutCopyOptions ( )

Definition at line 73 of file CommonCommandFlags.cpp.

73 {
74static CommandFlagOptions result{
75// In reporting the issue with cut or copy, we don't tell the user they could also select some text in a label.
76 []( const TranslatableString &Name ) {
77 // PRL: These strings have hard-coded mention of a certain shortcut key,
78 // thus assuming the default shortcuts. That is questionable.
80#ifdef __WXMAC__
81 // i18n-hint: %s will be replaced by the name of an action, such as Normalize, Cut, Fade.
82 format = XO("Select the audio for %s to use (for example, Cmd + A to Select All) then try again."
83 );
84
85#else
86 // i18n-hint: %s will be replaced by the name of an action, such as Normalize, Cut, Fade.
87 format = XO("Select the audio for %s to use (for example, Ctrl + A to Select All) then try again."
88 );
89#endif
90 return format.Format( Name );
91 },
92 "Selecting_Audio_-_the_basics",
93 XO("No Audio Selected")
94};
95return result;
96}

References anonymous_namespace{ExportPCM.cpp}::format, and XO().

Referenced by TimeSelectedFlag().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ EditableTracksSelectedFlag()

const ReservedCommandFlag & EditableTracksSelectedFlag ( )

Definition at line 171 of file CommonCommandFlags.cpp.

171 { static ReservedCommandFlag flag{
173 { []( const TranslatableString &Name ){ return
174 // i18n-hint: %s will be replaced by the name of an action, such as "Remove Tracks".
175 XO("\"%s\" requires one or more tracks to be selected.").Format( Name );
176 },"Audacity_Selection" }
177 }; return flag; }
bool EditableTracksSelectedPred(const AudacityProject &project)

References EditableTracksSelectedPred(), flag, and XO().

Referenced by anonymous_namespace{SelectMenus.cpp}::CursorMenu(), anonymous_namespace{EditMenus.cpp}::EditMenu(), anonymous_namespace{EditMenus.cpp}::ExtraEditMenu(), SelectUtilities::SelectAllIfNone(), SelectUtilities::SelectAllIfNoneAndAllowed(), anonymous_namespace{SelectMenus.cpp}::SelectMenu(), and anonymous_namespace{TrackMenus.cpp}::TracksMenu().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ EditableTracksSelectedPred()

bool EditableTracksSelectedPred ( const AudacityProject project)

Definition at line 45 of file CommonCommandFlags.cpp.

46{
47 auto range = TrackList::Get(project).Selected()
48 - [](const Track *pTrack){
49 return !pTrack->SupportsBasicEditing(); };
50 return !range.empty();
51};
Abstract base class for an object holding data associated with points on a time axis.
Definition: Track.h:110

References TrackList::Get(), project, and TrackList::Selected().

Referenced by anonymous_namespace{EditMenus.cpp}::CutCopyAvailableFlag(), and EditableTracksSelectedFlag().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ IsNotSyncLockedFlag()

const ReservedCommandFlag & IsNotSyncLockedFlag ( )

Definition at line 260 of file CommonCommandFlags.cpp.

260 { static ReservedCommandFlag flag{
261 [](const AudacityProject &project){
263 }
264 }; return flag; } //awd
bool IsSyncLocked() const
Definition: SyncLock.cpp:44
static SyncLockState & Get(AudacityProject &project)
Definition: SyncLock.cpp:27

References flag, SyncLockState::Get(), SyncLockState::IsSyncLocked(), and project.

Here is the call graph for this function:

◆ IsSyncLockedFlag()

const ReservedCommandFlag & IsSyncLockedFlag ( )

Definition at line 266 of file CommonCommandFlags.cpp.

266 { static ReservedCommandFlag flag{
267 [](const AudacityProject &project){
269 }
270 }; return flag; } //awd

References flag, SyncLockState::Get(), SyncLockState::IsSyncLocked(), and project.

Referenced by anonymous_namespace{SelectMenus.cpp}::SelectMenu().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ LabelTracksExistFlag()

const ReservedCommandFlag & LabelTracksExistFlag ( )

Definition at line 215 of file CommonCommandFlags.cpp.

215 { static ReservedCommandFlag flag{
216 [](const AudacityProject &project){
217 return !TrackList::Get(project)
218 .Selected<const LabelTrack>().empty();
219 }
220 }; return flag; }
A LabelTrack is a Track that holds labels (LabelStruct).
Definition: LabelTrack.h:98

References flag, TrackList::Get(), project, and TrackList::Selected().

Referenced by anonymous_namespace{FileMenus.cpp}::FileMenu().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ NoAutoSelect()

const ReservedCommandFlag & NoAutoSelect ( )

Definition at line 293 of file CommonCommandFlags.cpp.

293 { static ReservedCommandFlag flag{
294 [](const AudacityProject &){ return true; }
295 }; return flag; } // jkc

References flag.

Referenced by anonymous_namespace{EditMenus.cpp}::EditMenu(), and anonymous_namespace{EditMenus.cpp}::ExtraEditMenu().

Here is the caller graph for this function:

◆ NoiseReductionTimeSelectedFlag()

const ReservedCommandFlag & NoiseReductionTimeSelectedFlag ( )

Definition at line 144 of file CommonCommandFlags.cpp.

144 { static ReservedCommandFlag flag{
147 }; return flag; }
const CommandFlagOptions noiseReductionOptions
bool TimeSelectedPred(const AudacityProject &project)

References flag, noiseReductionOptions, and TimeSelectedPred().

Referenced by anonymous_namespace{MenuHelper.cpp}::FixBatchFlags().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ NotMinimizedFlag()

const ReservedCommandFlag & NotMinimizedFlag ( )

Definition at line 272 of file CommonCommandFlags.cpp.

272 { static ReservedCommandFlag flag{
273 [](const AudacityProject &project){
274 const wxWindow *focus = FindProjectFrame( &project );
275 if (focus) {
276 while (focus && focus->GetParent())
277 focus = focus->GetParent();
278 }
279 return (focus &&
280 !static_cast<const wxTopLevelWindow*>(focus)->IsIconized()
281 );
282 },
284 }; return flag; } // prl
wxFrame * FindProjectFrame(AudacityProject *project)
Get a pointer to the window associated with a project, or null if the given pointer is null,...

References FindProjectFrame(), flag, project, and CommandFlagOptions::QuickTest().

Here is the call graph for this function:

◆ PausedFlag()

const ReservedCommandFlag & PausedFlag ( )

Definition at line 286 of file CommonCommandFlags.cpp.

286 { static ReservedCommandFlag flag{
287 [](const AudacityProject&){
288 return AudioIOBase::Get()->IsPaused();
289 },
291 }; return flag; }
bool IsPaused() const
Find out if playback / recording is currently paused.

References flag, AudioIOBase::Get(), AudioIOBase::IsPaused(), and CommandFlagOptions::QuickTest().

Here is the call graph for this function:

◆ RedoAvailableFlag()

const ReservedCommandFlag & RedoAvailableFlag ( )

Definition at line 228 of file CommonCommandFlags.cpp.

228 { static ReservedCommandFlag flag{
229 [](const AudacityProject &project){
231 }
232 }; return flag; }
bool RedoAvailable() const
static ProjectHistory & Get(AudacityProject &project)

References flag, ProjectHistory::Get(), project, and ProjectHistory::RedoAvailable().

Referenced by anonymous_namespace{EditMenus.cpp}::EditMenu().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ StereoRequiredFlag()

const ReservedCommandFlag & StereoRequiredFlag ( )

Definition at line 130 of file CommonCommandFlags.cpp.

130 { static ReservedCommandFlag flag{
131 [](const AudacityProject &project){
132 // TODO: more-than-two-channels
133 auto range =
135 return std::any_of(range.begin(), range.end(),
136 [](auto pTrack){ return pTrack->NChannels() > 1; });
137 },
138 { []( const TranslatableString& ) { return
139 // This reason will not be shown, because the stereo-to-mono is greyed out if not allowed.
140 XO("You must first select some stereo audio to perform this\naction. (You cannot use this with mono.)");
141 } ,"Audacity_Selection"}
142 }; return flag; } //lda
A Track that contains audio waveform data.
Definition: WaveTrack.h:203

References flag, TrackList::Get(), project, TrackList::Selected(), and XO().

Referenced by anonymous_namespace{TrackMenus.cpp}::TracksMenu().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ TimeSelectedFlag()

const ReservedCommandFlag & TimeSelectedFlag ( )

Definition at line 149 of file CommonCommandFlags.cpp.

149 { static ReservedCommandFlag flag{
152 }; return flag; }
const CommandFlagOptions & cutCopyOptions()

References cutCopyOptions(), flag, and TimeSelectedPred().

Referenced by anonymous_namespace{PluginMenus.cpp}::AnalyzeMenu(), anonymous_namespace{SelectMenus.cpp}::CursorMenu(), anonymous_namespace{EditMenus.cpp}::EditMenu(), anonymous_namespace{PluginMenus.cpp}::EffectMenu(), anonymous_namespace{EditMenus.cpp}::ExtraEditMenu(), anonymous_namespace{FileMenus.cpp}::ExtraExportMenu(), anonymous_namespace{LabelMenus.cpp}::LabelEditMenus(), EffectUIHost::OnApply(), and anonymous_namespace{ViewMenus.cpp}::ViewMenu().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ TimeSelectedPred()

bool TimeSelectedPred ( const AudacityProject project)

Definition at line 66 of file CommonCommandFlags.cpp.

67{
68 // This is equivalent to check if there is a valid selection,
69 // so it's used for Zoom to Selection too
71};
bool isPoint() const
Definition: ViewInfo.h:40
NotifyingSelectedRegion selectedRegion
Definition: ViewInfo.h:216
static ViewInfo & Get(AudacityProject &project)
Definition: ViewInfo.cpp:235

References ViewInfo::Get(), NotifyingSelectedRegion::isPoint(), project, and ViewInfo::selectedRegion.

Referenced by anonymous_namespace{EditMenus.cpp}::CutCopyAvailableFlag(), NoiseReductionTimeSelectedFlag(), and TimeSelectedFlag().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ TrackPanelHasFocus()

const ReservedCommandFlag & TrackPanelHasFocus ( )

Definition at line 187 of file CommonCommandFlags.cpp.

187 { static ReservedCommandFlag flag{
188 [](const AudacityProject &project){
189 for (auto w = wxWindow::FindFocus(); w; w = w->GetParent()) {
190 if (dynamic_cast<const NonKeystrokeInterceptingWindow*>(w))
191 return true;
192 }
193 return false;
194 },
196 }; return flag; }; //lll
std::unique_ptr< WindowPlacement > FindFocus()
Find the window that is accepting keyboard input, if any.
Definition: BasicUI.h:383
CommandFlagOptions && DisableDefaultMessage() &&
Definition: CommandFlag.h:53

References CommandFlagOptions::DisableDefaultMessage(), BasicUI::FindFocus(), flag, and project.

Referenced by anonymous_namespace{SelectMenus.cpp}::ExtraCursorMenu(), anonymous_namespace{NavigationMenus.cpp}::ExtraFocusMenu(), anonymous_namespace{TransportMenus.cpp}::ExtraSelectionItems(), anonymous_namespace{SelectMenus.cpp}::ExtraSelectionMenu(), anonymous_namespace{ClipMenus.cpp}::ExtraTimeShiftItems(), and anonymous_namespace{TrackMenus.cpp}::ExtraTrackMenu().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ TracksExistFlag()

const ReservedCommandFlag & TracksExistFlag ( )

Definition at line 164 of file CommonCommandFlags.cpp.

164 { static ReservedCommandFlag flag{
165 [](const AudacityProject &project){
166 return !TrackList::Get(project).Any().empty();
167 },
169 }; return flag; }
auto Any() -> TrackIterRange< TrackType >
Definition: Track.h:950

References TrackList::Any(), CommandFlagOptions::DisableDefaultMessage(), flag, TrackList::Get(), and project.

Referenced by anonymous_namespace{SelectMenus.cpp}::ExtraCursorMenu(), anonymous_namespace{NavigationMenus.cpp}::ExtraFocusMenu(), anonymous_namespace{SelectMenus.cpp}::ExtraSelectionMenu(), anonymous_namespace{ClipMenus.cpp}::ExtraTimeShiftItems(), anonymous_namespace{TrackMenus.cpp}::ExtraTrackMenu(), anonymous_namespace{SelectMenus.cpp}::SelectMenu(), anonymous_namespace{SpectrumView.cpp}::SpectralSelectionMenu(), anonymous_namespace{TrackMenus.cpp}::TracksMenu(), and anonymous_namespace{ViewMenus.cpp}::ViewMenu().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ UndoAvailableFlag()

const ReservedCommandFlag & UndoAvailableFlag ( )

Definition at line 222 of file CommonCommandFlags.cpp.

222 { static ReservedCommandFlag flag{
223 [](const AudacityProject &project){
225 }
226 }; return flag; }
bool UndoAvailable() const

References flag, ProjectHistory::Get(), project, and ProjectHistory::UndoAvailable().

Referenced by anonymous_namespace{EditMenus.cpp}::EditMenu().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ WaveTracksExistFlag()

const ReservedCommandFlag & WaveTracksExistFlag ( )

Definition at line 254 of file CommonCommandFlags.cpp.

254 { static ReservedCommandFlag flag{
255 [](const AudacityProject &project){
256 return !TrackList::Get(project).Any<const WaveTrack>().empty();
257 }
258 }; return flag; }

References TrackList::Any(), flag, TrackList::Get(), and project.

Referenced by anonymous_namespace{ClipMenus.cpp}::ClipCursorItems(), anonymous_namespace{ClipMenus.cpp}::ClipSelectMenu(), anonymous_namespace{FileMenus.cpp}::ExtraExportMenu(), anonymous_namespace{TransportMenus.cpp}::ExtraTransportMenu(), anonymous_namespace{FileMenus.cpp}::FileMenu(), anonymous_namespace{LabelMenus.cpp}::LabelEditMenus(), anonymous_namespace{SelectMenus.cpp}::SelectMenu(), and anonymous_namespace{TransportMenus.cpp}::TransportMenu().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ WaveTracksSelectedFlag()

const ReservedCommandFlag & WaveTracksSelectedFlag ( )

Definition at line 154 of file CommonCommandFlags.cpp.

154 { static ReservedCommandFlag flag{
155 [](const AudacityProject &project){
156 return
157 !TrackList::Get(project).Selected<const WaveTrack>().empty();
158 },
159 { [](const TranslatableString&) { return
160 XO("You must first select some audio to perform this action.\n(Selecting other kinds of track won't work.)");
161 } ,"Audacity_Selection"}
162 }; return flag; }

References flag, TrackList::Get(), project, TrackList::Selected(), and XO().

Referenced by anonymous_namespace{PluginMenus.cpp}::AnalyzeMenu(), anonymous_namespace{EditMenus.cpp}::EditMenu(), anonymous_namespace{PluginMenus.cpp}::EffectMenu(), anonymous_namespace{FileMenus.cpp}::ExtraExportMenu(), EffectUIHost::OnApply(), anonymous_namespace{SelectMenus.cpp}::SelectMenu(), and anonymous_namespace{TrackMenus.cpp}::TracksMenu().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ ZoomInAvailableFlag()

const ReservedCommandFlag & ZoomInAvailableFlag ( )

Definition at line 234 of file CommonCommandFlags.cpp.

234 { static ReservedCommandFlag flag{
235 [](const AudacityProject &project){
236 return
238 &&
239 !TrackList::Get(project).Any().empty()
240 ;
241 }
242 }; return flag; }
bool ZoomInAvailable() const
Definition: ZoomInfo.cpp:65

References TrackList::Any(), flag, ViewInfo::Get(), TrackList::Get(), project, and ZoomInfo::ZoomInAvailable().

Referenced by anonymous_namespace{ViewMenus.cpp}::ViewMenu().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ ZoomOutAvailableFlag()

const ReservedCommandFlag & ZoomOutAvailableFlag ( )

Definition at line 244 of file CommonCommandFlags.cpp.

244 { static ReservedCommandFlag flag{
245 [](const AudacityProject &project){
246 return
248 &&
249 !TrackList::Get(project).Any().empty()
250 ;
251 }
252 }; return flag; }
bool ZoomOutAvailable() const
Definition: ZoomInfo.cpp:70

References TrackList::Any(), flag, ViewInfo::Get(), TrackList::Get(), project, and ZoomInfo::ZoomOutAvailable().

Referenced by anonymous_namespace{ViewMenus.cpp}::ViewMenu().

Here is the call graph for this function:
Here is the caller graph for this function:

Variable Documentation

◆ noiseReductionOptions

const CommandFlagOptions noiseReductionOptions
Initial value:
{
[]( const TranslatableString &Name ) {
auto format = XO("Select the audio for %s to use.\n\n1. Select audio that represents noise and use %s to get your 'noise profile'.\n\n2. When you have got your noise profile, select the audio you want to change\nand use %s to change that audio.");
return format.Format( Name, Name, Name );
},
"Noise_Reduction",
}

Definition at line 99 of file CommonCommandFlags.cpp.

Referenced by NoiseReductionTimeSelectedFlag().