Audacity  2.2.2
Menus.h
Go to the documentation of this file.
1 /**********************************************************************
2 
3  Audacity: A Digital Audio Editor
4 
5  Menus.h
6 
7  Dominic Mazzoni
8 
9 **********************************************************************/
10 #ifndef __AUDACITY_MENUS__
11 #define __AUDACITY_MENUS__
12 
13 #include "Experimental.h"
14 
15 
16 // These are all member functions of class AudacityProject.
17 // Vaughan, 2010-08-05:
18 // Note that this file is included in a "public" section of Project.h.
19 // Most of these methods do not need to be public, and because
20 // we do not subclass AudacityProject, they should be "private."
21 // Because the ones that need to be public are intermixed,
22 // I've added "private" in just a few cases.
23 
24 private:
26 
27 void PopulateEffectsMenu(CommandManager *c, EffectType type,
28  CommandFlag batchflags, CommandFlag realflags);
30  std::vector<const PluginDescriptor*> & plugs,
31  CommandFlag batchflags, CommandFlag realflags, bool isDefault);
32 void AddEffectMenuItemGroup(CommandManager *c, const wxArrayString & names,
33  const PluginIDList & plugs,
34  const std::vector<CommandFlag> & flags, bool isDefault);
36 void ModifyUndoMenuItems();
37 void ModifyToolbarMenus();
38 // Calls ModifyToolbarMenus() on all projects
40 
42 
43 public:
44 // If checkActive, do not do complete flags testing on an
45 // inactive project as it is needlessly expensive.
46 CommandFlag GetUpdateFlags(bool checkActive = false);
47 
48 //Adds label and returns index of label in labeltrack.
49 int DoAddLabel(const SelectedRegion& region, bool preserveFocus = false);
50 
51 private:
52 double NearestZeroCrossing(double t0);
53 
54  // Selecting a tool from the keyboard
55 
56 void SetTool(int tool);
57 void OnSelectTool(const CommandContext &context );
58 void OnZoomTool(const CommandContext &context );
59 void OnEnvelopeTool(const CommandContext &context );
60 void OnTimeShiftTool(const CommandContext &context );
61 void OnDrawTool(const CommandContext &context );
62 void OnMultiTool(const CommandContext &context );
63 
64 void OnNextTool(const CommandContext &context );
65 void OnPrevTool(const CommandContext &context );
66 
67 public:
68  // Audio I/O Commands
69 
70 void OnStop(const CommandContext &context );
71 void OnPause(const CommandContext &context );
72 void OnRecord(const CommandContext &context );
73 void OnRecord2ndChoice(const CommandContext &context );
74 void OnStopSelect(const CommandContext &context );
75 void OnSkipStart(const CommandContext &context );
76 void OnSkipEnd(const CommandContext &context );
77 void OnSeekLeftShort(const CommandContext &context );
78 void OnSeekRightShort(const CommandContext &context );
79 void OnSeekLeftLong(const CommandContext &context );
80 void OnSeekRightLong(const CommandContext &context );
81 
82  // Different posibilities for playing sound
83 
84 bool MakeReadyToPlay(bool loop = false, bool cutpreview = false); // Helper function that sets button states etc.
85 void OnPlayStop(const CommandContext &context );
86 bool DoPlayStopSelect(bool click, bool shift);
87 void OnPlayStopSelect(const CommandContext &context );
88 void OnPlayOneSecond(const CommandContext &context );
89 void OnPlayToSelection(const CommandContext &context );
90 void OnPlayBeforeSelectionStart(const CommandContext &context );
91 void OnPlayAfterSelectionStart(const CommandContext &context );
92 void OnPlayBeforeSelectionEnd(const CommandContext &context );
93 void OnPlayAfterSelectionEnd(const CommandContext &context );
96 void OnPlayLooped(const CommandContext &context );
97 void OnPlayCutPreview(const CommandContext &context );
98 
99  // Wave track control
100 
101 void OnTrackPan(const CommandContext &context );
102 void OnTrackPanLeft(const CommandContext &context );
103 void OnTrackPanRight(const CommandContext &context );
104 void OnTrackGain(const CommandContext &context );
105 void OnTrackGainInc(const CommandContext &context );
106 void OnTrackGainDec(const CommandContext &context );
107 void OnTrackMenu(const CommandContext &context );
108 void OnTrackMute(const CommandContext &context );
109 void OnTrackSolo(const CommandContext &context );
110 void OnTrackClose(const CommandContext &context );
111 void OnTrackMoveUp(const CommandContext &context );
112 void OnTrackMoveDown(const CommandContext &context );
113 void OnTrackMoveTop(const CommandContext &context );
114 void OnTrackMoveBottom(const CommandContext &context );
115 
117 void MoveTrack(Track* target, MoveChoice choice);
118 
119  // Device control
120 void OnInputDevice(const CommandContext &context );
121 void OnOutputDevice(const CommandContext &context );
122 void OnAudioHost(const CommandContext &context );
123 void OnInputChannels(const CommandContext &context );
124 
125  // Mixer control
126 
127 void OnOutputGain(const CommandContext &context );
128 void OnInputGain(const CommandContext &context );
129 void OnOutputGainInc(const CommandContext &context );
130 void OnOutputGainDec(const CommandContext &context );
131 void OnInputGainInc(const CommandContext &context );
132 void OnInputGainDec(const CommandContext &context );
133 
134  // Transcription control
135 
136 void OnPlayAtSpeed(const CommandContext &context );
137 void OnPlayAtSpeedLooped(const CommandContext &context );
138 void OnPlayAtSpeedCutPreview(const CommandContext &context );
139 void OnSetPlaySpeed(const CommandContext &context );
140 void OnPlaySpeedInc(const CommandContext &context );
141 void OnPlaySpeedDec(const CommandContext &context );
142 
143  // Moving track focus commands
144 
145 void OnPrevTrack( bool shift );
146 void OnNextTrack( bool shift );
147 void OnCursorUp(const CommandContext &context );
148 void OnCursorDown(const CommandContext &context );
149 void OnFirstTrack(const CommandContext &context );
150 void OnLastTrack(const CommandContext &context );
151 
152  // Selection-Editing Commands
153 
154 void OnShiftUp(const CommandContext &context );
155 void OnShiftDown(const CommandContext &context );
156 void OnToggle(const CommandContext &context );
157 
158 void HandleListSelection(Track *t, bool shift, bool ctrl, bool modifyState);
159 
160 void OnCursorLeft(const CommandContext &context );
161 void OnCursorRight(const CommandContext &context );
162 void OnSelExtendLeft(const CommandContext &context );
163 void OnSelExtendRight(const CommandContext &context );
164 void OnSelContractLeft(const CommandContext &context );
165 void OnSelContractRight(const CommandContext &context );
166 
167 public:
168 static double OnClipMove
169  (ViewInfo &viewInfo, Track *track,
170  TrackList &trackList, bool syncLocked, bool right);
171 
172 void DoClipLeftOrRight(bool right, bool keyUp );
173 void OnClipLeft(const CommandContext &context );
174 void OnClipRight(const CommandContext &context );
175 
176 void OnCursorShortJumpLeft(const CommandContext &context );
177 void OnCursorShortJumpRight(const CommandContext &context );
178 void OnCursorLongJumpLeft(const CommandContext &context );
179 void OnCursorLongJumpRight(const CommandContext &context );
180 void OnSelSetExtendLeft(const CommandContext &context );
181 void OnSelSetExtendRight(const CommandContext &context );
182 
183 void OnSetLeftSelection(const CommandContext &context );
184 void OnSetRightSelection(const CommandContext &context );
185 
186 void OnSelToStart(const CommandContext &context );
187 void OnSelToEnd(const CommandContext &context );
188 
189 void OnMoveToNextLabel(const CommandContext &context );
190 void OnMoveToPrevLabel(const CommandContext &context );
191 void OnMoveToLabel(bool next);
192 
193 void OnZeroCrossing(const CommandContext &context );
194 
195 void OnLockPlayRegion(const CommandContext &context );
196 void OnUnlockPlayRegion(const CommandContext &context );
197 
198 double GetTime(const Track *t);
199 void OnSortTime(const CommandContext &context );
200 void OnSortName(const CommandContext &context );
201 
202 void OnSnapToOff(const CommandContext &context );
203 void OnSnapToNearest(const CommandContext &context );
204 void OnSnapToPrior(const CommandContext &context );
205 void OnFullScreen(const CommandContext &context );
206 
207 static void DoMacMinimize(AudacityProject *project);
208 void OnMacMinimize(const CommandContext &context );
209 void OnMacMinimizeAll(const CommandContext &context );
210 void OnMacZoom(const CommandContext &context );
211 void OnMacBringAllToFront(const CommandContext &context );
212 
213  // File Menu
214 
215 void OnNew(const CommandContext &context );
216 void OnOpen(const CommandContext &context );
217 void OnClose(const CommandContext &context );
218 void OnSave(const CommandContext &context );
219 void OnSaveAs(const CommandContext &context );
220 #ifdef USE_LIBVORBIS
221  void OnSaveCompressed(const CommandContext &context );
222 #endif
223 
224 void OnCheckDependencies(const CommandContext &context );
225 
226 void OnExport(const wxString & Format);
227 void OnExportAudio(const CommandContext &context );
228 void OnExportMp3(const CommandContext &context );
229 void OnExportWav(const CommandContext &context );
230 void OnExportOgg(const CommandContext &context );
231 void OnExportSelection(const CommandContext &context );
232 void OnExportMultiple(const CommandContext &context );
233 void OnExportLabels(const CommandContext &context );
234 void OnExportMIDI(const CommandContext &context );
235 
236 void OnPreferences(const CommandContext &context );
237 
238 void OnPageSetup(const CommandContext &context );
239 void OnPrint(const CommandContext &context );
240 
241 void OnExit(const CommandContext &context );
242 
243  // Edit Menu
244 
245 public:
246 void OnUndo(const CommandContext &context );
247 void OnRedo(const CommandContext &context );
248 
249 private:
250 static void FinishCopy(const Track *n, Track *dest);
251 static void FinishCopy(const Track *n, Track::Holder &&dest, TrackList &list);
252 
253 public:
254 void OnCut(const CommandContext &context );
255 void OnSplitCut(const CommandContext &context );
256 void OnCopy(const CommandContext &context );
257 
258 void OnPaste(const CommandContext &context );
259 private:
260 bool HandlePasteText(); // Handle text paste (into active label), if any. Return true if pasted.
261 bool HandlePasteNothingSelected(); // Return true if nothing selected, regardless of paste result.
262 public:
263 
264 void OnPasteNewLabel(const CommandContext &context );
265 void OnPasteOver(const CommandContext &context );
266 void OnTrim(const CommandContext &context );
267 
268 void OnDelete(const CommandContext &context );
269 void OnSplitDelete(const CommandContext &context );
270 void OnSilence(const CommandContext &context );
271 
272 void OnSplit(const CommandContext &context );
273 void OnSplitNew(const CommandContext &context );
274 void OnJoin(const CommandContext &context );
275 void OnDisjoin(const CommandContext &context );
276 void OnDuplicate(const CommandContext &context );
277 
278 void OnCutLabels(const CommandContext &context );
279 void OnSplitCutLabels(const CommandContext &context );
280 void OnCopyLabels(const CommandContext &context );
281 void OnDeleteLabels(const CommandContext &context );
282 void OnSplitDeleteLabels(const CommandContext &context );
283 void OnSilenceLabels(const CommandContext &context );
284 void OnSplitLabels(const CommandContext &context );
285 void OnJoinLabels(const CommandContext &context );
286 void OnDisjoinLabels(const CommandContext &context );
287 
288 void OnSelectTimeAndTracks(bool bAllTime, bool bAllTracks);
289 void OnSelectAllTime(const CommandContext &context );
290 void OnSelectAllTracks(const CommandContext &context );
291 void OnSelectAll(const CommandContext &context );
292 void OnSelectSomething(const CommandContext &context );
293 void OnSelectNone(const CommandContext &context );
294 private:
296 int CountSelectedTracks();
297 public:
298 #ifdef EXPERIMENTAL_SPECTRAL_EDITING
299 // For toggling of spectral seletion
300 double mLastF0;
301 double mLastF1;
302 void OnToggleSpectralSelection(const CommandContext &context );
303 void DoNextPeakFrequency(bool up);
304 void OnNextHigherPeakFrequency(const CommandContext &context );
305 void OnNextLowerPeakFrequency(const CommandContext &context );
306 #endif
307 void OnSelectCursorEnd(const CommandContext &context );
308 void OnSelectStartCursor(const CommandContext &context );
311 void OnSelectClipBoundary(bool next);
312 struct FoundTrack {
314  int trackNumber{};
315  bool channel{};
316 
317  wxString ComposeTrackName() const;
318 };
320  bool found{};
321  double startTime{};
322  double endTime{};
323  int index{};
324 };
325 FoundClip FindNextClip(const WaveTrack* wt, double t0, double t1);
326 FoundClip FindPrevClip(const WaveTrack* wt, double t0, double t1);
327 int FindClips(double t0, double t1, bool next, std::vector<FoundClip>& results);
329 void OnSelectPrevClip(const CommandContext &context );
330 void OnSelectNextClip(const CommandContext &context );
331 void OnSelectClip(bool next);
332 void OnSelectCursorStoredCursor(const CommandContext &context );
333 void OnSelectSyncLockSel(const CommandContext &context );
334 
335 void OnZoomIn(const CommandContext &context );
336 void OnZoomOut(const CommandContext &context );
337 void OnZoomToggle(const CommandContext &context );
338 void OnZoomNormal(const CommandContext &context );
339 void OnZoomFit(const CommandContext &context );
340 void OnZoomFitV(const CommandContext &context );
341 void DoZoomFitV();
342 void OnZoomSel(const CommandContext &context );
343 void OnGoSelStart(const CommandContext &context );
344 void OnGoSelEnd(const CommandContext &context );
345 
346 void OnExpandAllTracks(const CommandContext &context );
347 void OnCollapseAllTracks(const CommandContext &context );
348 
349 void OnPanTracks(float PanValue);
350 void OnPanLeft(const CommandContext &context );
351 void OnPanRight(const CommandContext &context );
352 void OnPanCenter(const CommandContext &context );
353 
354 void OnMuteAllTracks(const CommandContext &context );
355 void OnUnMuteAllTracks(const CommandContext &context );
356 
357 void OnShowClipping(const CommandContext &context );
358 void OnShowExtraMenus(const CommandContext &context );
359 
360 void OnHistory(const CommandContext &context );
361 
362 void OnKaraoke(const CommandContext &context );
363 void OnMixerBoard(const CommandContext &context );
364 
365 void OnPlotSpectrum(const CommandContext &context );
366 void OnContrast(const CommandContext &context );
367 
368 void OnShowTransportToolBar(const CommandContext &context );
369 void OnShowDeviceToolBar(const CommandContext &context );
370 void OnShowEditToolBar(const CommandContext &context );
371 void OnShowMeterToolBar(const CommandContext &context );
372 void OnShowRecordMeterToolBar(const CommandContext &context );
373 void OnShowPlayMeterToolBar(const CommandContext &context );
374 void OnShowMixerToolBar(const CommandContext &context );
375 void OnShowSelectionToolBar(const CommandContext &context );
376 #ifdef EXPERIMENTAL_SPECTRAL_EDITING
377 void OnShowSpectralSelectionToolBar(const CommandContext &context );
378 #endif
379 void OnShowScrubbingToolBar(const CommandContext &context );
380 void OnShowToolsToolBar(const CommandContext &context );
381 void OnShowTranscriptionToolBar(const CommandContext &context );
382 void OnResetToolBars(const CommandContext &context );
383 
384 #if defined(EXPERIMENTAL_EFFECTS_RACK)
385 void OnShowEffectsRack(const CommandContext &context );
386 #endif
387 
388  // Transport Menu
389 
390 void OnSoundActivated(const CommandContext &context );
391 void OnToggleSoundActivated(const CommandContext &context );
392 void OnTogglePinnedHead(const CommandContext &context );
393 void OnTogglePlayRecording(const CommandContext &context );
394 void OnToggleSWPlaythrough(const CommandContext &context );
395 #ifdef EXPERIMENTAL_AUTOMATED_INPUT_LEVEL_ADJUSTMENT
396  void OnToggleAutomatedInputLevelAdjustment(const CommandContext &context );
397 #endif
398 void OnRescanDevices(const CommandContext &context );
399 
400 // Import Submenu
401 void OnImport(const CommandContext &context );
402 void OnImportLabels(const CommandContext &context );
403 void OnImportMIDI(const CommandContext &context );
404 
405 // return null on failure; if success, return the given project, or a NEW
406 // one, if the given was null; create no NEW project if failure
408  AudacityProject *pProject, const wxString &fileName);
409 
410 void OnImportRaw(const CommandContext &context );
411 
412 void OnEditMetadata(const CommandContext &context );
413 bool DoEditMetadata(const wxString &title, const wxString &shortUndoDescription, bool force);
414 
415 void OnMixAndRender(const CommandContext &context );
416 void OnMixAndRenderToNewTrack(const CommandContext &context );
417 void HandleMixAndRender(bool toNewTrack);
418 
419 private:
423 public:
424 void OnSelectionSave(const CommandContext &context );
425 void OnSelectionRestore(const CommandContext &context );
426 void OnCursorPositionStore(const CommandContext &context );
427 
428 void OnCursorTrackStart(const CommandContext &context );
429 void OnCursorTrackEnd(const CommandContext &context );
430 void OnCursorSelStart(const CommandContext &context );
431 void OnCursorSelEnd(const CommandContext &context );
433  int nFound{}; // 0, 1, or 2
434  double time{};
435  int index1{};
436  bool clipStart1{};
437  int index2{};
438  bool clipStart2{};
439 };
440 FoundClipBoundary FindNextClipBoundary(const WaveTrack* wt, double time);
441 FoundClipBoundary FindPrevClipBoundary(const WaveTrack* wt, double time);
442 double AdjustForFindingStartTimes(const std::vector<const WaveClip*>& clips, double time);
443 double AdjustForFindingEndTimes(const std::vector<const WaveClip*>& clips, double time);
444 int FindClipBoundaries(double time, bool next, std::vector<FoundClipBoundary>& results);
445 void OnCursorNextClipBoundary(const CommandContext &context );
446 void OnCursorPrevClipBoundary(const CommandContext &context );
447 void OnCursorClipBoundary(bool next);
448 static wxString ClipBoundaryMessage(const std::vector<FoundClipBoundary>& results);
449 
450 void OnAlignNoSync(const CommandContext &context );
451 void OnAlign(const CommandContext &context );
452 //void OnAlignMoveSel(int index);
453 void HandleAlign(int index, bool moveSel);
455 
456 #ifdef EXPERIMENTAL_SCOREALIGN
457 void OnScoreAlign(const CommandContext &context );
458 #endif // EXPERIMENTAL_SCOREALIGN
459 
460 // Tracks menu
461 void OnNewWaveTrack(const CommandContext &context );
462 void OnNewStereoTrack(const CommandContext &context );
463 void OnNewLabelTrack(const CommandContext &context );
464 void OnNewTimeTrack(const CommandContext &context );
465 void OnTimerRecord(const CommandContext &context );
466 void OnRemoveTracks(const CommandContext &context );
467 void OnMoveSelectionWithTracks(const CommandContext &context );
468 void OnSyncLock(const CommandContext &context );
469 void OnAddLabel(const CommandContext &context );
470 void OnAddLabelPlaying(const CommandContext &context );
471 void DoEditLabels(LabelTrack *lt = nullptr, int index = -1);
472 void OnEditLabels(const CommandContext &context );
473 void OnToggleTypeToCreateLabel(const CommandContext &context );
474 
475  // Effect Menu
476 
478 {
479 public:
480  // No flags specified
481  static const int kNone = 0x00;
482  // Flag used to disable prompting for configuration parameteres.
483  static const int kConfigured = 0x01;
484  // Flag used to disable saving the state after processing.
485  static const int kSkipState = 0x02;
486  // Flag used to disable "Repeat Last Effect"
487  static const int kDontRepeatLast = 0x04;
488 };
489 
490 bool DoEffect(const PluginID & ID, int flags);
491 void OnEffect(const CommandContext &context );
492 void OnRepeatLastEffect(const CommandContext &context );
493 void OnApplyChain(const CommandContext &context );
494 void OnEditChains(const CommandContext &context );
495 void OnStereoToMono(const CommandContext &context );
496 void OnManagePluginsMenu(EffectType Type);
497 static void RebuildAllMenuBars();
498 void OnManageGenerators(const CommandContext &context );
499 void OnManageEffects(const CommandContext &context );
500 void OnManageAnalyzers(const CommandContext &context );
501 
502 
503 
504  // Help Menu
505 
506 void OnAbout(const CommandContext &context );
507 void OnQuickHelp(const CommandContext &context );
508 void OnManual(const CommandContext &context );
509 void OnCheckForUpdates(const CommandContext &context );
510 void MayCheckForUpdates();
511 void OnShowLog(const CommandContext &context );
512 void OnHelpWelcome(const CommandContext &context );
513 void OnBenchmark(const CommandContext &context );
514 #if defined(EXPERIMENTAL_CRASH_REPORT)
515 void OnCrashReport(const CommandContext &context );
516 #endif
517 void OnSimulateRecordingErrors(const CommandContext &context );
518 void OnDetectUpstreamDropouts(const CommandContext &context );
519 void OnScreenshot(const CommandContext &context );
520 void OnAudioDeviceInfo(const CommandContext &context );
521 #ifdef EXPERIMENTAL_MIDI_OUT
522 void OnMidiDeviceInfo(const CommandContext &context );
523 #endif
524 
525  //
526 
527 void OnSeparator(const CommandContext &context );
528 
529  // Keyboard navigation
530 
531 void NextOrPrevFrame(bool next);
532 void PrevFrame(const CommandContext &context );
533 void NextFrame(const CommandContext &context );
534 
535 void PrevWindow(const CommandContext &context );
536 void NextWindow(const CommandContext &context );
537 
538 void OnResample(const CommandContext &context );
539 
540 private:
541 void OnCursorLeft(bool shift, bool ctrl, bool keyup = false);
542 void OnCursorRight(bool shift, bool ctrl, bool keyup = false);
543 void OnCursorMove(bool forward, bool jump, bool longjump);
544 void OnBoundaryMove(bool left, bool boundaryContract);
545 
546 // Handle small cursor and play head movements
547 void SeekLeftOrRight
548 (bool left, bool shift, bool ctrl, bool keyup,
549  int snapToTime, bool mayAccelerateQuiet, bool mayAccelerateAudio,
550  double quietSeekStepPositive, bool quietStepIsPixels,
551  double audioSeekStepPositive, bool audioStepIsPixels);
552 
553 // Helper for moving by keyboard with snap-to-grid enabled
554 double GridMove(double t, int minPix);
555 
556 // Make sure we return to "public" for subsequent declarations in Project.h.
557 public:
558 
559 #endif
560 
561 
562 
void OnRemoveTracks(const CommandContext &context)
void NextFrame(const CommandContext &context)
void OnExport(const wxString &Format)
void OnShowSpectralSelectionToolBar(const CommandContext &context)
void OnShowExtraMenus(const CommandContext &context)
void OnShowTransportToolBar(const CommandContext &context)
void OnExportMp3(const CommandContext &context)
void OnPlayBeforeSelectionStart(const CommandContext &context)
void OnZoomSel(const CommandContext &context)
void OnShowScrubbingToolBar(const CommandContext &context)
static wxArrayString names()
Definition: Tags.cpp:697
void OnEditLabels(const CommandContext &context)
static void RebuildAllMenuBars()
A list of TrackListNode items.
Definition: Track.h:611
void OnSplitCut(const CommandContext &context)
void OnExportMIDI(const CommandContext &context)
void OnToggleSWPlaythrough(const CommandContext &context)
void OnZoomOut(const CommandContext &context)
void OnCopyLabels(const CommandContext &context)
void OnSkipStart(const CommandContext &context)
void OnCursorLongJumpRight(const CommandContext &context)
void OnSplitDeleteLabels(const CommandContext &context)
void OnSave(const CommandContext &context)
void OnZoomIn(const CommandContext &context)
void OnPasteOver(const CommandContext &context)
void OnSelectAll(const CommandContext &context)
void OnManageGenerators(const CommandContext &context)
void OnPlaySpeedDec(const CommandContext &context)
void HandleListSelection(Track *t, bool shift, bool ctrl, bool modifyState)
void OnInputChannels(const CommandContext &context)
ViewInfo is used mainly to hold the zooming, selection and scroll information. It also has some statu...
Definition: ViewInfo.h:141
void OnCollapseAllTracks(const CommandContext &context)
void PopulateEffectsMenu(CommandManager *c, EffectType type, CommandFlag batchflags, CommandFlag realflags)
bool DoPlayStopSelect(bool click, bool shift)
void OnExit(const CommandContext &context)
void OnSelectCursorStoredCursor(const CommandContext &context)
static const int kConfigured
Definition: Menus.h:483
Abstract base class used in importing a file.
Definition: Import.h:32
void OnSelectSyncLockSel(const CommandContext &context)
void OnCursorLeft(const CommandContext &context)
void OnTrackMute(const CommandContext &context)
void OnPasteNewLabel(const CommandContext &context)
void OnMultiTool(const CommandContext &context)
void OnPlayToSelection(const CommandContext &context)
void OnSeekLeftLong(const CommandContext &context)
void DoClipLeftOrRight(bool right, bool keyUp)
void OnSplitCutLabels(const CommandContext &context)
void OnClipRight(const CommandContext &context)
void OnSyncLock(const CommandContext &context)
static AudacityProject * DoImportMIDI(AudacityProject *pProject, const wxString &fileName)
void OnExpandAllTracks(const CommandContext &context)
int index
Definition: Menus.h:323
void OnToggle(const CommandContext &context)
void OnMixerBoard(const CommandContext &context)
void OnTrackClose(const CommandContext &context)
void OnRecord2ndChoice(const CommandContext &context)
void OnClipLeft(const CommandContext &context)
static const int kSkipState
Definition: Menus.h:485
void OnSeparator(const CommandContext &context)
void OnStop(const CommandContext &context)
void OnEffect(const CommandContext &context)
void OnSelectNone(const CommandContext &context)
void OnPlayLooped(const CommandContext &context)
void OnTrim(const CommandContext &context)
void OnCursorClipBoundary(bool next)
void OnApplyChain(const CommandContext &context)
void OnCheckForUpdates(const CommandContext &context)
void OnMacZoom(const CommandContext &context)
void OnSelectClip(bool next)
void OnOutputGain(const CommandContext &context)
void OnCursorPrevClipBoundary(const CommandContext &context)
void OnTrackGainInc(const CommandContext &context)
void OnZoomFit(const CommandContext &context)
static void FinishCopy(const Track *n, Track *dest)
void OnNextLowerPeakFrequency(const CommandContext &context)
void OnCursorUp(const CommandContext &context)
void OnTrackGainDec(const CommandContext &context)
void OnSelectClipBoundary(bool next)
void OnShowToolsToolBar(const CommandContext &context)
void OnCursorLongJumpLeft(const CommandContext &context)
void OnOutputGainInc(const CommandContext &context)
void OnShowPlayMeterToolBar(const CommandContext &context)
void OnSplitDelete(const CommandContext &context)
void OnTrackMoveUp(const CommandContext &context)
void OnPrevTool(const CommandContext &context)
void OnPlayAfterSelectionStart(const CommandContext &context)
void OnMixAndRenderToNewTrack(const CommandContext &context)
void OnMixAndRender(const CommandContext &context)
void SeekLeftOrRight(bool left, bool shift, bool ctrl, bool keyup, int snapToTime, bool mayAccelerateQuiet, bool mayAccelerateAudio, double quietSeekStepPositive, bool quietStepIsPixels, double audioSeekStepPositive, bool audioStepIsPixels)
void AddEffectMenuItemGroup(CommandManager *c, const wxArrayString &names, const PluginIDList &plugs, const std::vector< CommandFlag > &flags, bool isDefault)
static const int kDontRepeatLast
Definition: Menus.h:487
void OnShowSelectionToolBar(const CommandContext &context)
void OnRecord(const CommandContext &context)
void NextOrPrevFrame(bool next)
void OnImportMIDI(const CommandContext &context)
void OnShowMeterToolBar(const CommandContext &context)
void PrevFrame(const CommandContext &context)
void OnShowTranscriptionToolBar(const CommandContext &context)
void OnResample(const CommandContext &context)
const WaveTrack * waveTrack
Definition: Menus.h:313
FoundClip FindNextClip(const WaveTrack *wt, double t0, double t1)
void OnSetLeftSelection(const CommandContext &context)
void OnLockPlayRegion(const CommandContext &context)
void OnCursorSelStart(const CommandContext &context)
void OnTimeShiftTool(const CommandContext &context)
void OnImportRaw(const CommandContext &context)
void OnSelExtendLeft(const CommandContext &context)
FoundClipBoundary FindNextClipBoundary(const WaveTrack *wt, double time)
void OnSelectCursorToNextClipBoundary(const CommandContext &context)
int FindClips(double t0, double t1, bool next, std::vector< FoundClip > &results)
void OnFullScreen(const CommandContext &context)
void OnUndo(const CommandContext &context)
void OnPageSetup(const CommandContext &context)
void OnCutLabels(const CommandContext &context)
void OnShowClipping(const CommandContext &context)
void OnAlignNoSync(const CommandContext &context)
bool clipStart2
Definition: Menus.h:438
void DoEditLabels(LabelTrack *lt=nullptr, int index=-1)
bool channel
Definition: Menus.h:315
void OnSelectPrevClip(const CommandContext &context)
void OnZoomToggle(const CommandContext &context)
void OnDisjoinLabels(const CommandContext &context)
void OnKaraoke(const CommandContext &context)
void OnPrint(const CommandContext &context)
void OnMoveToPrevLabel(const CommandContext &context)
void ModifyUndoMenuItems()
void OnShiftUp(const CommandContext &context)
wxArrayString PluginIDList
void OnPanTracks(float PanValue)
bool clipStart1
Definition: Menus.h:436
void OnPlayBeforeSelectionEnd(const CommandContext &context)
void OnOutputDevice(const CommandContext &context)
void OnMacMinimizeAll(const CommandContext &context)
void OnJoin(const CommandContext &context)
void OnSelectionRestore(const CommandContext &context)
void OnDelete(const CommandContext &context)
void OnEditMetadata(const CommandContext &context)
void OnPlayBeforeAndAfterSelectionEnd(const CommandContext &context)
void OnOpen(const CommandContext &context)
void OnEditChains(const CommandContext &context)
void OnSeekRightShort(const CommandContext &context)
void OnTrackMoveBottom(const CommandContext &context)
void OnAlign(const CommandContext &context)
FoundClip FindPrevClip(const WaveTrack *wt, double t0, double t1)
A LabelTrack is a Track that holds labels (LabelStruct).
Definition: LabelTrack.h:113
void OnTrackMenu(const CommandContext &context)
void OnMoveSelectionWithTracks(const CommandContext &context)
void OnNextHigherPeakFrequency(const CommandContext &context)
void OnCursorTrackEnd(const CommandContext &context)
void OnPreferences(const CommandContext &context)
void OnShowMixerToolBar(const CommandContext &context)
void OnNewStereoTrack(const CommandContext &context)
void ModifyAllProjectToolbarMenus()
void OnSeekRightLong(const CommandContext &context)
void OnShiftDown(const CommandContext &context)
void MayCheckForUpdates()
void OnTrackPanLeft(const CommandContext &context)
AudacityProject provides the main window, with tools and tracks contained within it.
Definition: Project.h:158
void OnUnMuteAllTracks(const CommandContext &context)
SelectedRegion mRegionSave
Definition: Menus.h:420
void OnSelSetExtendRight(const CommandContext &context)
void OnSimulateRecordingErrors(const CommandContext &context)
void OnShowLog(const CommandContext &context)
int DoAddLabel(const SelectedRegion &region, bool preserveFocus=false)
void OnTrackGain(const CommandContext &context)
int trackNumber
Definition: Menus.h:314
void OnManageEffects(const CommandContext &context)
bool ChannelsHaveSameClipBoundaries(const WaveTrack *wt)
void OnSnapToOff(const CommandContext &context)
void OnMuteAllTracks(const CommandContext &context)
void OnFirstTrack(const CommandContext &context)
void OnClose(const CommandContext &context)
void OnImportLabels(const CommandContext &context)
void OnShowEditToolBar(const CommandContext &context)
Defines a selected portion of a project.
void OnInputGain(const CommandContext &context)
void OnMoveToLabel(bool next)
void OnSelectTimeAndTracks(bool bAllTime, bool bAllTracks)
void OnCursorMove(bool forward, bool jump, bool longjump)
int CountSelectedTracks()
void OnCursorSelEnd(const CommandContext &context)
void OnTrackPan(const CommandContext &context)
void OnSelContractRight(const CommandContext &context)
void OnPaste(const CommandContext &context)
int FindClipBoundaries(double time, bool next, std::vector< FoundClipBoundary > &results)
void DoNextPeakFrequency(bool up)
void OnSplitLabels(const CommandContext &context)
void OnImport(const CommandContext &context)
void OnNewWaveTrack(const CommandContext &context)
void OnSelToEnd(const CommandContext &context)
void OnCursorRight(const CommandContext &context)
void OnTrackMoveTop(const CommandContext &context)
void OnPlayAfterSelectionEnd(const CommandContext &context)
double GridMove(double t, int minPix)
void OnGoSelStart(const CommandContext &context)
void OnExportOgg(const CommandContext &context)
void OnNewLabelTrack(const CommandContext &context)
void OnSelectAllTracks(const CommandContext &context)
A Track that contains audio waveform data.
Definition: WaveTrack.h:60
void OnInputGainInc(const CommandContext &context)
void OnPanLeft(const CommandContext &context)
void OnSelectCursorEnd(const CommandContext &context)
void OnToggleSpectralSelection(const CommandContext &context)
void NextWindow(const CommandContext &context)
CommandFlag GetUpdateFlags(bool checkActive=false)
FoundClipBoundary FindPrevClipBoundary(const WaveTrack *wt, double time)
Fundamental data object of Audacity, placed in the TrackPanel. Classes derived form it include the Wa...
Definition: Track.h:94
void OnLastTrack(const CommandContext &context)
void OnNextTool(const CommandContext &context)
void OnSaveAs(const CommandContext &context)
bool DoEditMetadata(const wxString &title, const wxString &shortUndoDescription, bool force)
CommandManager implements a system for organizing all user-callable commands.
void CreateRecentFilesMenu(CommandManager *c)
void OnSelectPrevClipBoundaryToCursor(const CommandContext &context)
static wxString ClipBoundaryMessage(const std::vector< FoundClipBoundary > &results)
void OnRepeatLastEffect(const CommandContext &context)
void OnZeroCrossing(const CommandContext &context)
void OnToggleSoundActivated(const CommandContext &context)
void OnSnapToPrior(const CommandContext &context)
size_t mAlignLabelsCount
Definition: Menus.h:454
void OnTimerRecord(const CommandContext &context)
bool HandlePasteNothingSelected()
void OnDeleteLabels(const CommandContext &context)
void OnSetRightSelection(const CommandContext &context)
void OnScreenshot(const CommandContext &context)
void OnExportAudio(const CommandContext &context)
void OnCursorPositionStore(const CommandContext &context)
double GetTime(const Track *t)
void OnTogglePlayRecording(const CommandContext &context)
void OnPlotSpectrum(const CommandContext &context)
void OnPlayAtSpeedLooped(const CommandContext &context)
void DoZoomFitV()
void OnCursorShortJumpRight(const CommandContext &context)
void OnZoomNormal(const CommandContext &context)
void OnCut(const CommandContext &context)
void OnQuickHelp(const CommandContext &context)
void OnContrast(const CommandContext &context)
void OnSetPlaySpeed(const CommandContext &context)
static void DoMacMinimize(AudacityProject *project)
void OnSelToStart(const CommandContext &context)
static const int kNone
Definition: Menus.h:481
double startTime
Definition: Menus.h:321
void OnAbout(const CommandContext &context)
void OnShowRecordMeterToolBar(const CommandContext &context)
void ModifyToolbarMenus()
void OnManual(const CommandContext &context)
void OnSelectionSave(const CommandContext &context)
void OnExportWav(const CommandContext &context)
double NearestZeroCrossing(double t0)
CommandFlag GetFocusedFrame()
bool HandlePasteText()
void OnMacBringAllToFront(const CommandContext &context)
void OnAudioDeviceInfo(const CommandContext &context)
void OnSoundActivated(const CommandContext &context)
void OnSilenceLabels(const CommandContext &context)
void OnRescanDevices(const CommandContext &context)
void HandleAlign(int index, bool moveSel)
double AdjustForFindingEndTimes(const std::vector< const WaveClip * > &clips, double time)
CommandFlag
Definition: CommandFlag.h:16
void OnCursorNextClipBoundary(const CommandContext &context)
double mCursorPositionStored
Definition: Menus.h:422
void OnHistory(const CommandContext &context)
void OnSelExtendRight(const CommandContext &context)
bool MakeReadyToPlay(bool loop=false, bool cutpreview=false)
void OnSelContractLeft(const CommandContext &context)
void OnZoomFitV(const CommandContext &context)
void OnDisjoin(const CommandContext &context)
void OnStopSelect(const CommandContext &context)
void OnBoundaryMove(bool left, bool boundaryContract)
int CountSelectedWaveTracks()
void OnPlayAtSpeedCutPreview(const CommandContext &context)
void OnSilence(const CommandContext &context)
void OnSelectTool(const CommandContext &context)
void OnDuplicate(const CommandContext &context)
void OnSelSetExtendLeft(const CommandContext &context)
void OnCursorDown(const CommandContext &context)
void SetTool(int tool)
void OnPlayStopSelect(const CommandContext &context)
void OnPanCenter(const CommandContext &context)
void OnManageAnalyzers(const CommandContext &context)
void OnShowDeviceToolBar(const CommandContext &context)
void OnTrackPanRight(const CommandContext &context)
double mLastF1
Definition: Menus.h:301
void OnDrawTool(const CommandContext &context)
void OnTrackSolo(const CommandContext &context)
void OnPlayStop(const CommandContext &context)
void OnExportMultiple(const CommandContext &context)
void OnStereoToMono(const CommandContext &context)
void OnRedo(const CommandContext &context)
MoveChoice
Definition: Menus.h:116
void OnInputDevice(const CommandContext &context)
void OnJoinLabels(const CommandContext &context)
void OnSortTime(const CommandContext &context)
void OnNewTimeTrack(const CommandContext &context)
void OnResetToolBars(const CommandContext &context)
void CreateMenusAndCommands()
void OnSortName(const CommandContext &context)
void MoveTrack(Track *target, MoveChoice choice)
void OnCursorShortJumpLeft(const CommandContext &context)
void OnAddLabel(const CommandContext &context)
void OnPlayOneSecond(const CommandContext &context)
void OnInputGainDec(const CommandContext &context)
void OnDetectUpstreamDropouts(const CommandContext &context)
void OnBenchmark(const CommandContext &context)
std::unique_ptr< Track > Holder
Definition: Track.h:256
static double OnClipMove(ViewInfo &viewInfo, Track *track, TrackList &trackList, bool syncLocked, bool right)
double mLastF0
Definition: Menus.h:300
bool mCursorPositionHasBeenStored
Definition: Menus.h:421
void OnNextTrack(bool shift)
void PrevWindow(const CommandContext &context)
void OnPause(const CommandContext &context)
bool found
Definition: Menus.h:320
wxString ComposeTrackName() const
void OnSelectNextClip(const CommandContext &context)
void OnSeekLeftShort(const CommandContext &context)
void OnHelpWelcome(const CommandContext &context)
void OnSplit(const CommandContext &context)
void OnSnapToNearest(const CommandContext &context)
void OnToggleTypeToCreateLabel(const CommandContext &context)
void OnPlayCutPreview(const CommandContext &context)
void OnZoomTool(const CommandContext &context)
void OnTogglePinnedHead(const CommandContext &context)
void OnSkipEnd(const CommandContext &context)
void OnCopy(const CommandContext &context)
void OnSplitNew(const CommandContext &context)
void OnCursorTrackStart(const CommandContext &context)
double endTime
Definition: Menus.h:322
void OnNew(const CommandContext &context)
void OnSelectSomething(const CommandContext &context)
void OnAddLabelPlaying(const CommandContext &context)
void OnOutputGainDec(const CommandContext &context)
void OnPlayAtSpeed(const CommandContext &context)
void OnPanRight(const CommandContext &context)
double time
Definition: Menus.h:434
void AddEffectMenuItems(CommandManager *c, std::vector< const PluginDescriptor * > &plugs, CommandFlag batchflags, CommandFlag realflags, bool isDefault)
void OnGoSelEnd(const CommandContext &context)
void OnMacMinimize(const CommandContext &context)
void OnManagePluginsMenu(EffectType Type)
void OnPlaySpeedInc(const CommandContext &context)
void OnExportLabels(const CommandContext &context)
double AdjustForFindingStartTimes(const std::vector< const WaveClip * > &clips, double time)
void OnAudioHost(const CommandContext &context)
void OnExportSelection(const CommandContext &context)
void OnEnvelopeTool(const CommandContext &context)
void OnSelectStartCursor(const CommandContext &context)
void OnPrevTrack(bool shift)
void OnCheckDependencies(const CommandContext &context)
void OnSelectAllTime(const CommandContext &context)
void OnUnlockPlayRegion(const CommandContext &context)
bool DoEffect(const PluginID &ID, int flags)
void OnMoveToNextLabel(const CommandContext &context)
void OnPlayBeforeAndAfterSelectionStart(const CommandContext &context)
void OnTrackMoveDown(const CommandContext &context)
void HandleMixAndRender(bool toNewTrack)