Audacity 3.2.0
TrackPanelResizerCell.h
Go to the documentation of this file.
1/**********************************************************************
2
3 Audacity: A Digital Audio Editor
4
5 TrackPanelResizerCell.h
6
7 Paul Licameli split from TrackPanel.cpp
8
9 **********************************************************************/
10
11#ifndef __AUDACITY_TRACK_PANEL_RESIZER_CELL__
12#define __AUDACITY_TRACK_PANEL_RESIZER_CELL__
13
14#include "ClientData.h" // to inherit
15#include "tracks/ui/CommonTrackPanelCell.h" // to inherit
16
17class Channel;
19
21 : public CommonTrackCell
22 , public std::enable_shared_from_this< TrackPanelResizerCell >
23{
26public:
27
28 static TrackPanelResizerCell &Get(Channel &channel);
29 static const TrackPanelResizerCell &Get(const Channel &channel);
30
34 explicit TrackPanelResizerCell(Channel &channel);
35
36 std::vector<UIHandlePtr> HitTest
37 (const TrackPanelMouseState &, const AudacityProject *) override;
38
39private:
40
41 // TrackPanelDrawable implementation
42 void Draw(
44 const wxRect &rect, unsigned iPass ) override;
45
46 std::weak_ptr<TrackPanelResizeHandle> mResizeHandle;
47};
48
49#endif
Utility ClientData::Site to register hooks into a host class that attach client data.
The top-level handle to an Audacity project. It serves as a source of events that other objects can b...
Definition: Project.h:90
Constructed from one channel, but changes height of all channels in a track.
std::weak_ptr< TrackPanelResizeHandle > mResizeHandle
TrackPanelResizerCell(const TrackPanelResizerCell &)=delete
void Draw(TrackPanelDrawingContext &context, const wxRect &rect, unsigned iPass) override
static TrackPanelResizerCell & Get(Channel &channel)
TrackPanelResizerCell & operator=(const TrackPanelResizerCell &)=delete
std::vector< UIHandlePtr > HitTest(const TrackPanelMouseState &, const AudacityProject *) override