Audacity 3.2.0
UIHandle.cpp
Go to the documentation of this file.
1/**********************************************************************
2
3Audacity: A Digital Audio Editor
4
5UIHandle.cpp
6
7Paul Licameli
8
9**********************************************************************/
10#include "UIHandle.h"
11#include "Channel.h"
12#include "RefreshCode.h"
13#include "Track.h"
14
16{
17}
18
20{
21}
22
24{
25 return false;
26}
27
29{
30 return false;
31}
32
34{
35 return false;
36}
37
39{
40 return false;
41}
42
44{
45 return false;
46}
47
49{
50 return false;
51}
52
54{
55}
56
58{
59 return false;
60}
61
62std::shared_ptr<const Track>
63UIHandle::TrackFromChannel(const std::shared_ptr<const Channel> &pChannel)
64{
65 return pChannel
66 ? static_cast<const Track &>(pChannel->GetChannelGroup())
67 .shared_from_this()
68 : nullptr;
69}
Abstract class ChannelGroup with two discrete iterable dimensions, channels and intervals; subclasses...
declares abstract base class Track, TrackList, and iterators over TrackList
The top-level handle to an Audacity project. It serves as a source of events that other objects can b...
Definition: Project.h:90
Abstract base class for an object holding data associated with points on a time axis.
Definition: Track.h:110
static std::shared_ptr< const Track > TrackFromChannel(const std::shared_ptr< const Channel > &pChannel)
A frequent convenience in the definition of UIHandles.
Definition: UIHandle.cpp:63
virtual ~UIHandle()=0
Definition: UIHandle.cpp:15
virtual bool HasRotation() const
Definition: UIHandle.cpp:23
virtual void Enter(bool forward, AudacityProject *pProject)
Definition: UIHandle.cpp:19
virtual bool Rotate(bool forward)
Definition: UIHandle.cpp:28
virtual bool StopsOnKeystroke()
Definition: UIHandle.cpp:48
virtual bool IsDragging() const
Definition: UIHandle.cpp:57
virtual bool HasEscape(AudacityProject *pProject) const
Definition: UIHandle.cpp:33
virtual bool HandlesRightClick()
Whether the handle has any special right-button handling.
Definition: UIHandle.cpp:43
virtual bool Escape(AudacityProject *pProject)
Definition: UIHandle.cpp:38
virtual void OnProjectChange(AudacityProject *pProject)
Definition: UIHandle.cpp:53