1
0
mirror of https://github.com/cookiengineer/audacity synced 2025-07-31 07:59:27 +02:00
audacity/src/tracks/ui/CommonTrackView.h
Paul Licameli c882564994 Move drawing of TrackName from the subview to VRulersAndChannels...
... And thus do it only once per channel (i.e. once per set of sub-views)
2019-12-29 15:31:03 -05:00

52 lines
1.3 KiB
C++

/**********************************************************************
Audacity: A Digital Audio Editor
CommonTrackView.h
Paul Licameli split from class TrackView
**********************************************************************/
#ifndef __AUDACITY_COMMON_TRACK_VIEW__
#define __AUDACITY_COMMON_TRACK_VIEW__
#include "TrackView.h" // to inherit
class SelectHandle;
class TimeShiftHandle;
class CommonTrackView /* not final */ : public TrackView
{
public:
using TrackView::TrackView;
// Delegates the handling to the related TCP cell
std::shared_ptr<TrackPanelCell> ContextMenuDelegate() override;
// Cause certain overriding tool modes (Zoom; future ones?) to behave
// uniformly in all tracks, disregarding track contents.
// Do not further override this...
std::vector<UIHandlePtr> HitTest
(const TrackPanelMouseState &, const AudacityProject *pProject)
final override;
void TimeShiftHitTest();
virtual int GetMinimizedHeight() const override;
protected:
// Rather override this for subclasses:
virtual std::vector<UIHandlePtr> DetailedHitTest
(const TrackPanelMouseState &,
const AudacityProject *pProject, int currentTool, bool bMultiTool)
= 0;
std::weak_ptr<SelectHandle> mSelectHandle;
public:
std::weak_ptr<TimeShiftHandle> mTimeShiftHandle;
};
#endif