Audacity 3.2.0
|
#include <CommonTrackPanelCell.h>
Classes | |
struct | MenuItem |
struct | MouseWheelHook |
Public Member Functions | |
CommonTrackPanelCell () | |
virtual | ~CommonTrackPanelCell ()=0 |
HitTestPreview | DefaultPreview (const TrackPanelMouseState &, const AudacityProject *) override |
std::shared_ptr< Track > | FindTrack () |
std::shared_ptr< const Track > | FindTrack () const |
virtual std::vector< MenuItem > | GetMenuItems (const wxRect &rect, const wxPoint *pPosition, AudacityProject *pProject) |
Return a list of items for DoContextMenu() (empties for separators) More... | |
Public Member Functions inherited from TrackPanelCell | |
TrackPanelCell ()=default | |
TrackPanelCell (const TrackPanelCell &)=delete | |
TrackPanelCell & | operator= (const TrackPanelCell &)=delete |
virtual | ~TrackPanelCell ()=0 |
virtual HitTestPreview | DefaultPreview (const TrackPanelMouseState &state, const AudacityProject *pProject) |
virtual std::vector< UIHandlePtr > | HitTest (const TrackPanelMouseState &state, const AudacityProject *pProject)=0 |
virtual unsigned | HandleWheelRotation (const TrackPanelMouseEvent &event, AudacityProject *pProject) |
virtual std::shared_ptr< TrackPanelCell > | ContextMenuDelegate () |
virtual unsigned | DoContextMenu (const wxRect &rect, wxWindow *pParent, const wxPoint *pPosition, AudacityProject *pProject) |
virtual unsigned | CaptureKey (wxKeyEvent &event, ViewInfo &viewInfo, wxWindow *pParent, AudacityProject *project) |
virtual unsigned | KeyDown (wxKeyEvent &event, ViewInfo &viewInfo, wxWindow *pParent, AudacityProject *project) |
virtual unsigned | KeyUp (wxKeyEvent &event, ViewInfo &viewInfo, wxWindow *pParent, AudacityProject *project) |
virtual unsigned | Char (wxKeyEvent &event, ViewInfo &viewInfo, wxWindow *pParent, AudacityProject *project) |
virtual unsigned | LoseFocus (AudacityProject *project) |
Public Member Functions inherited from TrackPanelNode | |
TrackPanelNode () | |
virtual | ~TrackPanelNode ()=0 |
Public Member Functions inherited from TrackPanelDrawable | |
virtual | ~TrackPanelDrawable ()=0 |
virtual void | Draw (TrackPanelDrawingContext &context, const wxRect &rect, unsigned iPass) |
virtual wxRect | DrawingArea (TrackPanelDrawingContext &context, const wxRect &rect, const wxRect &panelRect, unsigned iPass) |
Protected Member Functions | |
virtual std::shared_ptr< Track > | DoFindTrack ()=0 |
unsigned | DoContextMenu (const wxRect &rect, wxWindow *pParent, const wxPoint *pPosition, AudacityProject *pProject) override |
unsigned | HandleWheelRotation (const TrackPanelMouseEvent &event, AudacityProject *pProject) override |
Additional Inherited Members | |
Static Public Member Functions inherited from TrackPanelDrawable | |
static wxRect | MaximizeWidth (const wxRect &rect, const wxRect &panelRect) |
static wxRect | MaximizeHeight (const wxRect &rect, const wxRect &panelRect) |
Definition at line 32 of file CommonTrackPanelCell.h.
|
inline |
Definition at line 41 of file CommonTrackPanelCell.h.
|
pure virtual |
Definition at line 28 of file CommonTrackPanelCell.cpp.
|
overridevirtual |
Reimplemented from TrackPanelCell.
Definition at line 32 of file CommonTrackPanelCell.cpp.
|
overrideprotectedvirtual |
Reimplemented from TrackPanelCell.
Definition at line 46 of file CommonTrackPanelCell.cpp.
References FindTrack(), CommandManager::Get(), ViewInfo::Get(), GetMenuItems(), label, BasicMenu::Handle::Popup(), ZoomInfo::PositionToTime(), RefreshCode::RefreshNone, and BasicUI::Point::x.
|
protectedpure virtual |
|
inline |
Definition at line 50 of file CommonTrackPanelCell.h.
Referenced by ChannelView::AdjustPositions(), CommonChannelView::ContextMenuDelegate(), CommonTrackControls::DoContextMenu(), DoContextMenu(), SelectHandle::Drag(), LabelTrackView::Draw(), NoteTrackAffordanceControls::Draw(), WaveTrackAffordanceControls::Draw(), CommonTrackControls::Draw(), WaveTrackAffordanceControls::ExitTextEditing(), CommonChannelView::HitTest(), CommonTrackControls::HitTest(), NoteTrackAffordanceControls::HitTest(), NoteTrackControls::HitTest(), WaveTrackAffordanceControls::HitTest(), WaveTrackControls::HitTest(), WaveTrackAffordanceControls::OnRenderClipStretching(), WaveTrackAffordanceControls::StartEditSelectedClipName(), and WaveTrackAffordanceControls::StartEditSelectedClipSpeed().
|
inline |
Definition at line 51 of file CommonTrackPanelCell.h.
|
virtual |
Return a list of items for DoContextMenu() (empties for separators)
If the vector is empty (as in the default), there is no context menu.
Commands are invoked with temporary selection fields of CommandContext set to a point selected region at the mouse pick, and the cell's track.
A function may be given, but if it is null, then the command can be found by name in the CommandManager.
An item in the list with no command name marks a menu separator.
The menu item is enabled only if it contains a true flag, but if looked up in the command manager, it must also satisfy the command manager's conditions.
Reimplemented in WaveChannelSubView, WaveTrackAffordanceControls, and BackgroundCell.
Definition at line 39 of file CommonTrackPanelCell.cpp.
Referenced by DoContextMenu().
|
overrideprotectedvirtual |
Reimplemented from TrackPanelCell.
Definition at line 111 of file CommonTrackPanelCell.cpp.
References RefreshCode::Cancelled, and GlobalVariable< MouseWheelHook, const std::function< unsigned(const TrackPanelMouseEvent &evt, AudacityProject *pProject) >, nullptr, Options... >::Get().