Audacity 3.2.0
Public Member Functions | Private Attributes | List of all members
anonymous_namespace{CellularPanel.cpp}::DefaultRightButtonHandler Class Reference
Inheritance diagram for anonymous_namespace{CellularPanel.cpp}::DefaultRightButtonHandler:
[legend]
Collaboration diagram for anonymous_namespace{CellularPanel.cpp}::DefaultRightButtonHandler:
[legend]

Public Member Functions

 DefaultRightButtonHandler (const std::shared_ptr< TrackPanelCell > &pCell)
 
 ~DefaultRightButtonHandler () override
 
std::shared_ptr< const TrackFindTrack () const override
 
virtual Result Click (const TrackPanelMouseEvent &event, AudacityProject *pProject) override
 
virtual Result Drag (const TrackPanelMouseEvent &event, AudacityProject *pProject) override
 
virtual HitTestPreview Preview (const TrackPanelMouseState &state, AudacityProject *pProject) override
 
virtual Result Release (const TrackPanelMouseEvent &event, AudacityProject *pProject, wxWindow *pParent) override
 
virtual Result Cancel (AudacityProject *pProject) override
 
- Public Member Functions inherited from UIHandle
virtual ~UIHandle ()=0
 
virtual void Enter (bool forward, AudacityProject *pProject)
 
virtual bool HasRotation () const
 
virtual bool Rotate (bool forward)
 
virtual bool HasEscape (AudacityProject *pProject) const
 
virtual bool Escape (AudacityProject *pProject)
 
virtual bool HandlesRightClick ()
 Whether the handle has any special right-button handling. More...
 
virtual Result Click (const TrackPanelMouseEvent &event, AudacityProject *pProject)=0
 
virtual Result Drag (const TrackPanelMouseEvent &event, AudacityProject *pProject)=0
 
virtual HitTestPreview Preview (const TrackPanelMouseState &state, AudacityProject *pProject)=0
 
virtual Result Release (const TrackPanelMouseEvent &event, AudacityProject *pProject, wxWindow *pParent)=0
 
virtual Result Cancel (AudacityProject *pProject)=0
 
virtual bool StopsOnKeystroke ()
 
virtual void OnProjectChange (AudacityProject *pProject)
 
virtual std::shared_ptr< const TrackFindTrack () const =0
 
virtual bool IsDragging () const
 
Result GetChangeHighlight () const
 
void SetChangeHighlight (Result val)
 
- 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)
 

Private Attributes

std::weak_ptr< TrackPanelCellmwCell
 

Additional Inherited Members

- Public Types inherited from UIHandle
using Result = unsigned
 
using Cell = TrackPanelCell
 
- Static Public Member Functions inherited from UIHandle
static UIHandle::Result NeedChangeHighlight (const UIHandle &, const UIHandle &)
 
static std::shared_ptr< const TrackTrackFromChannel (const std::shared_ptr< const Channel > &pChannel)
 A frequent convenience in the definition of UIHandles. More...
 
- 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)
 
- Protected Attributes inherited from UIHandle
Result mChangeHighlight { 0 }
 

Detailed Description

Definition at line 854 of file CellularPanel.cpp.

Constructor & Destructor Documentation

◆ DefaultRightButtonHandler()

anonymous_namespace{CellularPanel.cpp}::DefaultRightButtonHandler::DefaultRightButtonHandler ( const std::shared_ptr< TrackPanelCell > &  pCell)
inlineexplicit

Definition at line 856 of file CellularPanel.cpp.

858 : mwCell{ pCell }
859 {}

◆ ~DefaultRightButtonHandler()

anonymous_namespace{CellularPanel.cpp}::DefaultRightButtonHandler::~DefaultRightButtonHandler ( )
override

Definition at line 904 of file CellularPanel.cpp.

905{
906}

Member Function Documentation

◆ Cancel()

virtual Result anonymous_namespace{CellularPanel.cpp}::DefaultRightButtonHandler::Cancel ( AudacityProject pProject)
inlineoverridevirtual

Implements UIHandle.

Definition at line 895 of file CellularPanel.cpp.

896 {
898 }

References RefreshCode::RefreshNone.

◆ Click()

virtual Result anonymous_namespace{CellularPanel.cpp}::DefaultRightButtonHandler::Click ( const TrackPanelMouseEvent event,
AudacityProject pProject 
)
inlineoverridevirtual

Implements UIHandle.

Definition at line 866 of file CellularPanel.cpp.

868 {
870 }

References RefreshCode::RefreshNone.

◆ Drag()

virtual Result anonymous_namespace{CellularPanel.cpp}::DefaultRightButtonHandler::Drag ( const TrackPanelMouseEvent event,
AudacityProject pProject 
)
inlineoverridevirtual

Implements UIHandle.

Definition at line 872 of file CellularPanel.cpp.

874 {
876 }

References RefreshCode::RefreshNone.

◆ FindTrack()

std::shared_ptr< const Track > anonymous_namespace{CellularPanel.cpp}::DefaultRightButtonHandler::FindTrack ( ) const
inlineoverridevirtual
Returns
pointer to associated track, if any

Implements UIHandle.

Definition at line 863 of file CellularPanel.cpp.

864 { return nullptr; }

◆ Preview()

virtual HitTestPreview anonymous_namespace{CellularPanel.cpp}::DefaultRightButtonHandler::Preview ( const TrackPanelMouseState state,
AudacityProject pProject 
)
inlineoverridevirtual

Implements UIHandle.

Definition at line 878 of file CellularPanel.cpp.

880 {
881 return {};
882 }

◆ Release()

virtual Result anonymous_namespace{CellularPanel.cpp}::DefaultRightButtonHandler::Release ( const TrackPanelMouseEvent event,
AudacityProject pProject,
wxWindow *  pParent 
)
inlineoverridevirtual

Implements UIHandle.

Definition at line 884 of file CellularPanel.cpp.

887 {
888 if (auto pCell = mwCell.lock()) {
889 auto point = event.event.GetPosition();
890 return pCell->DoContextMenu(event.rect, pParent, &point, pProject);
891 }
893 }

References TrackPanelMouseEvent::rect, and RefreshCode::RefreshNone.

Member Data Documentation

◆ mwCell

std::weak_ptr<TrackPanelCell> anonymous_namespace{CellularPanel.cpp}::DefaultRightButtonHandler::mwCell
private

Definition at line 901 of file CellularPanel.cpp.


The documentation for this class was generated from the following file: