Audacity 3.2.0
NoteTrackControls.h
Go to the documentation of this file.
1/**********************************************************************
2
3Audacity: A Digital Audio Editor
4
5NoteTrackControls.h
6
7Paul Licameli split from TrackPanel.cpp
8
9**********************************************************************/
10
11#ifndef __AUDACITY_NOTE_TRACK_CONTROLS__
12#define __AUDACITY_NOTE_TRACK_CONTROLS__
13
14#include "../../ui/PlayableTrackControls.h" // to inherit
15#include "Observer.h"
16
17class wxEvent;
18class LWSlider;
19class NoteTrack;
23class VelocitySliderHandle;
24
25
26
28#ifdef EXPERIMENTAL_MIDI_OUT
30#else
32#endif
33 ;
34
37{
40
41 std::weak_ptr<MuteButtonHandle> mMuteHandle;
42 std::weak_ptr<SoloButtonHandle> mSoloHandle;
43 std::weak_ptr<NoteTrackButtonHandle> mClickHandle;
44 std::weak_ptr<VelocitySliderHandle> mVelocityHandle;
45
46public:
47 explicit
48 NoteTrackControls( std::shared_ptr<Track> pTrack )
49 : NoteTrackControlsBase( pTrack ) {}
51
52 std::vector<UIHandlePtr> HitTest
53 (const TrackPanelMouseState &state,
54 const AudacityProject *pProject) override;
55
56 PopupMenuTable *GetMenuExtension(Track *pTrack) override;
57
58 const TCPLines& GetTCPLines() const override;
59
60 static unsigned DefaultNoteTrackHeight();
61 static void GetMidiControlsRect(const wxRect & rect, wxRect & dest);
62 static void GetVelocityRect(const wxPoint &topleft, wxRect & dest);
63
65 (const wxRect &sliderRect, const NoteTrack *t, bool captured,
66 wxWindow *pParent);
67
68private:
70};
71
72#endif
std::vector< TrackInfo::TCPLine > TCPLines
The top-level handle to an Audacity project. It serves as a source of events that other objects can b...
Definition: Project.h:90
Lightweight version of ASlider. In other words it does not have a window permanently associated with ...
Definition: ASlider.h:64
static void ReCreateVelocitySlider(struct ThemeChangeMessage)
NoteTrackControls(std::shared_ptr< Track > pTrack)
static void GetMidiControlsRect(const wxRect &rect, wxRect &dest)
std::weak_ptr< NoteTrackButtonHandle > mClickHandle
std::weak_ptr< SoloButtonHandle > mSoloHandle
PopupMenuTable * GetMenuExtension(Track *pTrack) override
std::weak_ptr< VelocitySliderHandle > mVelocityHandle
static unsigned DefaultNoteTrackHeight()
const TCPLines & GetTCPLines() const override
static void GetVelocityRect(const wxPoint &topleft, wxRect &dest)
static LWSlider * VelocitySlider(const wxRect &sliderRect, const NoteTrack *t, bool captured, wxWindow *pParent)
NoteTrackControls(const NoteTrackControls &)=delete
NoteTrackControls & operator=(const NoteTrackControls &)=delete
std::weak_ptr< MuteButtonHandle > mMuteHandle
std::vector< UIHandlePtr > HitTest(const TrackPanelMouseState &state, const AudacityProject *pProject) override
A Track that is used for Midi notes. (Somewhat old code).
Definition: NoteTrack.h:86
Abstract base class for an object holding data associated with points on a time axis.
Definition: Track.h:122