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;
24
25
26
29{
32
33 std::weak_ptr<MuteButtonHandle> mMuteHandle;
34 std::weak_ptr<SoloButtonHandle> mSoloHandle;
35 std::weak_ptr<NoteTrackButtonHandle> mClickHandle;
36 std::weak_ptr<VelocitySliderHandle> mVelocityHandle;
37
38public:
39 explicit
40 NoteTrackControls( std::shared_ptr<Track> pTrack )
41 : PlayableTrackControls( pTrack ) {}
43
44 std::vector<UIHandlePtr> HitTest
45 (const TrackPanelMouseState &state,
46 const AudacityProject *pProject) override;
47
48 PopupMenuTable *GetMenuExtension(Track *pTrack) override;
49
50 const TCPLines& GetTCPLines() const override;
51
52 static unsigned DefaultNoteTrackHeight();
53 static void GetMidiControlsRect(const wxRect & rect, wxRect & dest);
54 static void GetVelocityRect(const wxPoint &topleft, wxRect & dest);
55
57 (const wxRect &sliderRect, const NoteTrack *t, bool captured,
58 wxWindow *pParent);
59
60private:
62};
63
64#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)
static LWSlider * VelocitySlider(const wxRect &sliderRect, const NoteTrack *t, bool captured, wxWindow *pParent)
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)
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:78
Abstract base class for an object holding data associated with points on a time axis.
Definition: Track.h:110