mirror of
https://github.com/Ardour/ardour.git
synced 2026-01-06 13:45:43 +01:00
Add API to query editor's playhead cursor position
This commit is contained in:
parent
cd64f17a9c
commit
e1826f8b1c
3 changed files with 9 additions and 1 deletions
|
|
@ -4546,6 +4546,12 @@ Editor::set_samples_per_pixel (framecnt_t spp)
|
|||
instant_save ();
|
||||
}
|
||||
|
||||
framepos_t
|
||||
Editor::playhead_cursor_sample () const
|
||||
{
|
||||
return playhead_cursor->current_frame();
|
||||
}
|
||||
|
||||
void
|
||||
Editor::queue_visual_videotimeline_update ()
|
||||
{
|
||||
|
|
|
|||
|
|
@ -1015,7 +1015,8 @@ class Editor : public PublicEditor, public PBD::ScopedConnectionList, public ARD
|
|||
|
||||
friend class EditorCursor;
|
||||
|
||||
EditorCursor* playhead_cursor;
|
||||
EditorCursor* playhead_cursor;
|
||||
framepos_t playhead_cursor_sample () const;
|
||||
|
||||
framepos_t get_region_boundary (framepos_t pos, int32_t dir, bool with_selection, bool only_onscreen);
|
||||
|
||||
|
|
|
|||
|
|
@ -197,6 +197,7 @@ class PublicEditor : public Gtkmm2ext::Tabbable {
|
|||
|
||||
virtual void transition_to_rolling (bool fwd) = 0;
|
||||
virtual framepos_t pixel_to_sample (double pixel) const = 0;
|
||||
virtual framepos_t playhead_cursor_sample () const = 0;
|
||||
virtual double sample_to_pixel (framepos_t frame) const = 0;
|
||||
virtual double sample_to_pixel_unrounded (framepos_t frame) const = 0;
|
||||
virtual Selection& get_selection () const = 0;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue