NAP
Public Member Functions | Protected Member Functions | List of all members
SequenceEventTrackView Class Referencefinal

#include <sequenceeventtrackview.h>

Public Member Functions

 SequenceEventTrackView (SequenceGUIService &service, SequenceEditorGUIView &view, SequenceEditorGUIState &state)
 
 SequenceEventTrackView (const SequenceEventTrackView &)=delete
 
SequenceEventTrackViewoperator= (const SequenceEventTrackView &)=delete
 
- Public Member Functions inherited from SequenceTrackView
 SequenceTrackView (SequenceEditorGUIView &view, SequenceEditorGUIState &state)
 
virtual ~SequenceTrackView ()=default
 
virtual void handleActions ()
 
virtual void showInspector (const SequenceTrack &track)
 
virtual void showTrack (const SequenceTrack &track)
 

Protected Member Functions

void showInspectorContent (const SequenceTrack &track) override
 
void showTrackContent (const SequenceTrack &track, const ImVec2 &trackTopLeft) override
 
void handleInsertEventSegmentPopup ()
 
template<typename T >
void handleEditEventSegmentPopup ()
 
bool pasteEventsFromClipboard (const std::string &trackID, double time, utility::ErrorState &errorState)
 
template<typename T >
void pasteEvent (const std::string &trackID, const SequenceTrackSegmentEventBase &baseEvent, double time)
 
void drawSegmentHandler (const SequenceTrack &track, const SequenceTrackSegment &segment, const ImVec2 &trackTopLeft, float segmentX, float segmentWidth, ImDrawList *drawList)
 
void handleEditSegmentValuePopup ()
 
void updateSegmentInClipboard (const std::string &trackID, const std::string &segmentID)
 
void handleAssignOutputIDToTrack ()
 
void handleSegmentDrag ()
 
void handleLoadPresetPopup ()
 
- Protected Member Functions inherited from SequenceTrackView
void handleTrackOptionsPopup ()
 
void registerActionHandler (const rttr::type &type, const std::function< void()> &handler)
 
const SequencePlayergetPlayer ()
 
SequenceEditorgetEditor ()
 

Additional Inherited Members

- Static Public Member Functions inherited from SequenceTrackView
static bool Combo (const char *label, int *currIndex, std::vector< std::string > &values)
 
static bool ListBox (const char *label, int *currIndex, std::vector< std::string > &values)
 
static std::string formatTimeString (double time)
 
- Protected Attributes inherited from SequenceTrackView
SequenceEditorGUIViewmView
 
SequenceEditorGUIStatemState
 
std::unordered_map< rttr::type, std::function< void()> > mActionHandlers
 
SequenceGUIServicemService
 

Description

SequenceEventTrackView is a view for event tracks

Inheritance diagram for SequenceEventTrackView:
[legend]
Collaboration diagram for SequenceEventTrackView:
[legend]

Constructor & Destructor Documentation

◆ SequenceEventTrackView() [1/2]

Constructor

Parameters
servicereference to gui service
viewreference to editor view
statereference to editor state

◆ SequenceEventTrackView() [2/2]

Member Function Documentation

◆ drawSegmentHandler()

void drawSegmentHandler ( const SequenceTrack track,
const SequenceTrackSegment segment,
const ImVec2 &  trackTopLeft,
float  segmentX,
float  segmentWidth,
ImDrawList *  drawList 
)
protected

draws segment handler

Parameters
trackreference to track
segmentreference to segment
trackTopLefttracks topleft position
segmentXsegment x position
segmentWidthwidth of segment
drawListpointer to window drawlist

◆ handleAssignOutputIDToTrack()

void handleAssignOutputIDToTrack ( )
protected

handles assigning of new output id to track

◆ handleEditEventSegmentPopup()

void handleEditEventSegmentPopup
protected

handles event segment popup

◆ handleEditSegmentValuePopup()

void handleEditSegmentValuePopup ( )
protected

handles delete segment popup

◆ handleInsertEventSegmentPopup()

void handleInsertEventSegmentPopup ( )
protected

handles insert event segment popup

◆ handleLoadPresetPopup()

void handleLoadPresetPopup ( )
protected

◆ handleSegmentDrag()

void handleSegmentDrag ( )
protected

handles dragging of event segment

◆ operator=()

SequenceEventTrackView& operator= ( const SequenceEventTrackView )
delete

◆ pasteEvent()

void pasteEvent ( const std::string &  trackID,
const SequenceTrackSegmentEventBase baseEvent,
double  time 
)
protected

Paste events of type T. Base event is base class of event of type T

Template Parameters
Ttype of event
Parameters
trackIDtrack on which to paste event
baseEventreference to base class of event to paste
timetime in seconds

◆ pasteEventsFromClipboard()

bool pasteEventsFromClipboard ( const std::string &  trackID,
double  time,
utility::ErrorState errorState 
)
protected

handles pasting of clipboard content to event segment

Template Parameters
Tthe event segment type
Parameters
trackIDthe track id of where to paste the new event
timethe time where to insert copied event segment
errorStatecontains any errors
Returns
true on succes

◆ showInspectorContent()

void showInspectorContent ( const SequenceTrack track)
overrideprotectedvirtual

shows inspector content

Parameters
trackreference to track

Implements SequenceTrackView.

◆ showTrackContent()

void showTrackContent ( const SequenceTrack track,
const ImVec2 &  trackTopLeft 
)
overrideprotectedvirtual

shows track contents

Parameters
trackreference to track
trackTopLeftorientation

Implements SequenceTrackView.

◆ updateSegmentInClipboard()

void updateSegmentInClipboard ( const std::string &  trackID,
const std::string &  segmentID 
)
protected

update the segment in the clipboard

Parameters
trackIDthe track id of the track containing the segment
segmentIDthe segment id