mirror of
https://github.com/Ardour/ardour.git
synced 2025-12-07 07:14:56 +01:00
add API to fetch all regionviews after a given position
This commit is contained in:
parent
a1ef870866
commit
12b536d8f2
7 changed files with 33 additions and 0 deletions
|
|
@ -268,6 +268,8 @@ public:
|
||||||
bool get_selection_extents (samplepos_t &start, samplepos_t &end) const; // the time extents of the current selection, whether Range, Region(s), Control Points, or Notes
|
bool get_selection_extents (samplepos_t &start, samplepos_t &end) const; // the time extents of the current selection, whether Range, Region(s), Control Points, or Notes
|
||||||
Selection& get_cut_buffer() const { return *cut_buffer; }
|
Selection& get_cut_buffer() const { return *cut_buffer; }
|
||||||
|
|
||||||
|
void get_regionviews_at_or_after (ARDOUR::samplepos_t, RegionSelection&);
|
||||||
|
|
||||||
void set_selection (std::list<Selectable*>, Selection::Operation);
|
void set_selection (std::list<Selectable*>, Selection::Operation);
|
||||||
void set_selected_midi_region_view (MidiRegionView&);
|
void set_selected_midi_region_view (MidiRegionView&);
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -2257,6 +2257,14 @@ Editor::select_all_selectables_between (bool within)
|
||||||
commit_reversible_selection_op ();
|
commit_reversible_selection_op ();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void
|
||||||
|
Editor::get_regionviews_at_or_after (samplepos_t pos, RegionSelection& regions)
|
||||||
|
{
|
||||||
|
for (TrackViewList::iterator iter = track_views.begin(); iter != track_views.end(); ++iter) {
|
||||||
|
(*iter)->get_regionviews_at_or_after (pos, regions);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
Editor::select_range_between ()
|
Editor::select_range_between ()
|
||||||
{
|
{
|
||||||
|
|
|
||||||
|
|
@ -1170,6 +1170,16 @@ RouteTimeAxisView::get_inverted_selectables (Selection& sel, list<Selectable*>&
|
||||||
StripableTimeAxisView::get_inverted_selectables (sel, results);
|
StripableTimeAxisView::get_inverted_selectables (sel, results);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void
|
||||||
|
RouteTimeAxisView::get_regionviews_at_or_after (samplepos_t pos, RegionSelection& regions)
|
||||||
|
{
|
||||||
|
if (!_view) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
_view->get_regionviews_at_or_after (pos, regions);
|
||||||
|
}
|
||||||
|
|
||||||
RouteGroup*
|
RouteGroup*
|
||||||
RouteTimeAxisView::route_group () const
|
RouteTimeAxisView::route_group () const
|
||||||
{
|
{
|
||||||
|
|
|
||||||
|
|
@ -102,6 +102,7 @@ public:
|
||||||
void set_selected_regionviews (RegionSelection&);
|
void set_selected_regionviews (RegionSelection&);
|
||||||
void get_selectables (ARDOUR::samplepos_t start, ARDOUR::samplepos_t end, double top, double bot, std::list<Selectable *>&, bool within = false);
|
void get_selectables (ARDOUR::samplepos_t start, ARDOUR::samplepos_t end, double top, double bot, std::list<Selectable *>&, bool within = false);
|
||||||
void get_inverted_selectables (Selection&, std::list<Selectable*>&);
|
void get_inverted_selectables (Selection&, std::list<Selectable*>&);
|
||||||
|
void get_regionviews_at_or_after (ARDOUR::samplepos_t, RegionSelection&);
|
||||||
void set_layer_display (LayerDisplay d);
|
void set_layer_display (LayerDisplay d);
|
||||||
void toggle_layer_display ();
|
void toggle_layer_display ();
|
||||||
LayerDisplay layer_display () const;
|
LayerDisplay layer_display () const;
|
||||||
|
|
|
||||||
|
|
@ -601,6 +601,16 @@ StreamView::get_inverted_selectables (Selection& sel, list<Selectable*>& results
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void
|
||||||
|
StreamView::get_regionviews_at_or_after (samplepos_t pos, RegionSelection& regions)
|
||||||
|
{
|
||||||
|
for (list<RegionView*>::iterator i = region_views.begin(); i != region_views.end(); ++i) {
|
||||||
|
if ((*i)->region()->position() >= pos) {
|
||||||
|
regions.push_back (*i);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/** @return height of a child region view, depending on stacked / overlaid mode */
|
/** @return height of a child region view, depending on stacked / overlaid mode */
|
||||||
double
|
double
|
||||||
StreamView::child_height () const
|
StreamView::child_height () const
|
||||||
|
|
|
||||||
|
|
@ -106,6 +106,7 @@ public:
|
||||||
void set_selected_regionviews (RegionSelection&);
|
void set_selected_regionviews (RegionSelection&);
|
||||||
void get_selectables (ARDOUR::samplepos_t, ARDOUR::samplepos_t, double, double, std::list<Selectable* >&, bool within = false);
|
void get_selectables (ARDOUR::samplepos_t, ARDOUR::samplepos_t, double, double, std::list<Selectable* >&, bool within = false);
|
||||||
void get_inverted_selectables (Selection&, std::list<Selectable* >& results);
|
void get_inverted_selectables (Selection&, std::list<Selectable* >& results);
|
||||||
|
void get_regionviews_at_or_after (ARDOUR::samplepos_t, RegionSelection&);
|
||||||
|
|
||||||
virtual void update_contents_metrics(boost::shared_ptr<ARDOUR::Region>) {}
|
virtual void update_contents_metrics(boost::shared_ptr<ARDOUR::Region>) {}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -212,6 +212,7 @@ public:
|
||||||
|
|
||||||
virtual void get_selectables (ARDOUR::samplepos_t, ARDOUR::samplepos_t, double, double, std::list<Selectable*>&, bool within = false);
|
virtual void get_selectables (ARDOUR::samplepos_t, ARDOUR::samplepos_t, double, double, std::list<Selectable*>&, bool within = false);
|
||||||
virtual void get_inverted_selectables (Selection&, std::list<Selectable *>& results);
|
virtual void get_inverted_selectables (Selection&, std::list<Selectable *>& results);
|
||||||
|
virtual void get_regionviews_at_or_after (ARDOUR::samplepos_t, RegionSelection&) {}
|
||||||
|
|
||||||
void add_ghost (RegionView*);
|
void add_ghost (RegionView*);
|
||||||
void remove_ghost (RegionView*);
|
void remove_ghost (RegionView*);
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue