no-op - whitespace fix for libs/ardour/playlist.cc
This commit is contained in:
parent
86a471f93f
commit
666ed3a0bd
@ -651,9 +651,9 @@ Playlist::flush_notifications (bool from_undo)
|
|||||||
in_flush = false;
|
in_flush = false;
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
Playlist::clear_pending ()
|
Playlist::clear_pending ()
|
||||||
{
|
{
|
||||||
pending_adds.clear ();
|
pending_adds.clear ();
|
||||||
pending_removes.clear ();
|
pending_removes.clear ();
|
||||||
pending_bounds.clear ();
|
pending_bounds.clear ();
|
||||||
@ -661,16 +661,16 @@ Playlist::flush_notifications (bool from_undo)
|
|||||||
pending_region_extensions.clear ();
|
pending_region_extensions.clear ();
|
||||||
pending_contents_change = false;
|
pending_contents_change = false;
|
||||||
pending_layering = false;
|
pending_layering = false;
|
||||||
}
|
}
|
||||||
|
|
||||||
/*************************************************************
|
/*************************************************************
|
||||||
PLAYLIST OPERATIONS
|
PLAYLIST OPERATIONS
|
||||||
*************************************************************/
|
*************************************************************/
|
||||||
|
|
||||||
/** Note: this calls set_layer (..., DBL_MAX) so it will reset the layering index of region */
|
/** Note: this calls set_layer (..., DBL_MAX) so it will reset the layering index of region */
|
||||||
void
|
void
|
||||||
Playlist::add_region (boost::shared_ptr<Region> region, framepos_t position, float times, bool auto_partition, const int32_t sub_num)
|
Playlist::add_region (boost::shared_ptr<Region> region, framepos_t position, float times, bool auto_partition, const int32_t sub_num)
|
||||||
{
|
{
|
||||||
RegionWriteLock rlock (this);
|
RegionWriteLock rlock (this);
|
||||||
times = fabs (times);
|
times = fabs (times);
|
||||||
|
|
||||||
@ -728,11 +728,11 @@ Playlist::flush_notifications (bool from_undo)
|
|||||||
}
|
}
|
||||||
|
|
||||||
possibly_splice_unlocked (position, (pos + length) - position, region);
|
possibly_splice_unlocked (position, (pos + length) - position, region);
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
Playlist::set_region_ownership ()
|
Playlist::set_region_ownership ()
|
||||||
{
|
{
|
||||||
RegionWriteLock rl (this);
|
RegionWriteLock rl (this);
|
||||||
RegionList::iterator i;
|
RegionList::iterator i;
|
||||||
boost::weak_ptr<Playlist> pl (shared_from_this());
|
boost::weak_ptr<Playlist> pl (shared_from_this());
|
||||||
@ -740,11 +740,11 @@ Playlist::flush_notifications (bool from_undo)
|
|||||||
for (i = regions.begin(); i != regions.end(); ++i) {
|
for (i = regions.begin(); i != regions.end(); ++i) {
|
||||||
(*i)->set_playlist (pl);
|
(*i)->set_playlist (pl);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
bool
|
bool
|
||||||
Playlist::add_region_internal (boost::shared_ptr<Region> region, framepos_t position, const int32_t sub_num)
|
Playlist::add_region_internal (boost::shared_ptr<Region> region, framepos_t position, const int32_t sub_num)
|
||||||
{
|
{
|
||||||
if (region->data_type() != _type) {
|
if (region->data_type() != _type) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
@ -776,11 +776,11 @@ Playlist::flush_notifications (bool from_undo)
|
|||||||
region->DropReferences.connect_same_thread (region_drop_references_connections, boost::bind (&Playlist::region_going_away, this, boost::weak_ptr<Region> (region)));
|
region->DropReferences.connect_same_thread (region_drop_references_connections, boost::bind (&Playlist::region_going_away, this, boost::weak_ptr<Region> (region)));
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
Playlist::replace_region (boost::shared_ptr<Region> old, boost::shared_ptr<Region> newr, framepos_t pos)
|
Playlist::replace_region (boost::shared_ptr<Region> old, boost::shared_ptr<Region> newr, framepos_t pos)
|
||||||
{
|
{
|
||||||
RegionWriteLock rlock (this);
|
RegionWriteLock rlock (this);
|
||||||
|
|
||||||
bool old_sp = _splicing;
|
bool old_sp = _splicing;
|
||||||
@ -793,18 +793,18 @@ Playlist::flush_notifications (bool from_undo)
|
|||||||
_splicing = old_sp;
|
_splicing = old_sp;
|
||||||
|
|
||||||
possibly_splice_unlocked (pos, old->length() - newr->length());
|
possibly_splice_unlocked (pos, old->length() - newr->length());
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
Playlist::remove_region (boost::shared_ptr<Region> region)
|
Playlist::remove_region (boost::shared_ptr<Region> region)
|
||||||
{
|
{
|
||||||
RegionWriteLock rlock (this);
|
RegionWriteLock rlock (this);
|
||||||
remove_region_internal (region);
|
remove_region_internal (region);
|
||||||
}
|
}
|
||||||
|
|
||||||
int
|
int
|
||||||
Playlist::remove_region_internal (boost::shared_ptr<Region> region)
|
Playlist::remove_region_internal (boost::shared_ptr<Region> region)
|
||||||
{
|
{
|
||||||
RegionList::iterator i;
|
RegionList::iterator i;
|
||||||
|
|
||||||
if (!in_set_state) {
|
if (!in_set_state) {
|
||||||
@ -835,11 +835,11 @@ Playlist::flush_notifications (bool from_undo)
|
|||||||
}
|
}
|
||||||
|
|
||||||
return -1;
|
return -1;
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
Playlist::get_equivalent_regions (boost::shared_ptr<Region> other, vector<boost::shared_ptr<Region> >& results)
|
Playlist::get_equivalent_regions (boost::shared_ptr<Region> other, vector<boost::shared_ptr<Region> >& results)
|
||||||
{
|
{
|
||||||
if (Config->get_use_overlap_equivalency()) {
|
if (Config->get_use_overlap_equivalency()) {
|
||||||
for (RegionList::iterator i = regions.begin(); i != regions.end(); ++i) {
|
for (RegionList::iterator i = regions.begin(); i != regions.end(); ++i) {
|
||||||
if ((*i)->overlap_equivalent (other)) {
|
if ((*i)->overlap_equivalent (other)) {
|
||||||
@ -853,33 +853,33 @@ Playlist::flush_notifications (bool from_undo)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
Playlist::get_region_list_equivalent_regions (boost::shared_ptr<Region> other, vector<boost::shared_ptr<Region> >& results)
|
Playlist::get_region_list_equivalent_regions (boost::shared_ptr<Region> other, vector<boost::shared_ptr<Region> >& results)
|
||||||
{
|
{
|
||||||
for (RegionList::iterator i = regions.begin(); i != regions.end(); ++i) {
|
for (RegionList::iterator i = regions.begin(); i != regions.end(); ++i) {
|
||||||
|
|
||||||
if ((*i) && (*i)->region_list_equivalent (other)) {
|
if ((*i) && (*i)->region_list_equivalent (other)) {
|
||||||
results.push_back (*i);
|
results.push_back (*i);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
Playlist::get_source_equivalent_regions (boost::shared_ptr<Region> other, vector<boost::shared_ptr<Region> >& results)
|
Playlist::get_source_equivalent_regions (boost::shared_ptr<Region> other, vector<boost::shared_ptr<Region> >& results)
|
||||||
{
|
{
|
||||||
for (RegionList::iterator i = regions.begin(); i != regions.end(); ++i) {
|
for (RegionList::iterator i = regions.begin(); i != regions.end(); ++i) {
|
||||||
|
|
||||||
if ((*i) && (*i)->any_source_equivalent (other)) {
|
if ((*i) && (*i)->any_source_equivalent (other)) {
|
||||||
results.push_back (*i);
|
results.push_back (*i);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
Playlist::partition (framepos_t start, framepos_t end, bool cut)
|
Playlist::partition (framepos_t start, framepos_t end, bool cut)
|
||||||
{
|
{
|
||||||
RegionList thawlist;
|
RegionList thawlist;
|
||||||
{
|
{
|
||||||
RegionWriteLock lock(this);
|
RegionWriteLock lock(this);
|
||||||
@ -889,16 +889,16 @@ Playlist::flush_notifications (bool from_undo)
|
|||||||
for (RegionList::iterator i = thawlist.begin(); i != thawlist.end(); ++i) {
|
for (RegionList::iterator i = thawlist.begin(); i != thawlist.end(); ++i) {
|
||||||
(*i)->resume_property_changes ();
|
(*i)->resume_property_changes ();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/** Go through each region on the playlist and cut them at start and end, removing the section between
|
/** Go through each region on the playlist and cut them at start and end, removing the section between
|
||||||
* start and end if cutting == true. Regions that lie entirely within start and end are always
|
* start and end if cutting == true. Regions that lie entirely within start and end are always
|
||||||
* removed.
|
* removed.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
void
|
void
|
||||||
Playlist::partition_internal (framepos_t start, framepos_t end, bool cutting, RegionList& thawlist)
|
Playlist::partition_internal (framepos_t start, framepos_t end, bool cutting, RegionList& thawlist)
|
||||||
{
|
{
|
||||||
RegionList new_regions;
|
RegionList new_regions;
|
||||||
|
|
||||||
{
|
{
|
||||||
@ -1132,11 +1132,11 @@ Playlist::flush_notifications (bool from_undo)
|
|||||||
//keep track of any dead space at end (for pasting into Ripple or Splice mode)
|
//keep track of any dead space at end (for pasting into Ripple or Splice mode)
|
||||||
framepos_t wanted_length = end-start;
|
framepos_t wanted_length = end-start;
|
||||||
_end_space = wanted_length - _get_extent().second - _get_extent().first;
|
_end_space = wanted_length - _get_extent().second - _get_extent().first;
|
||||||
}
|
}
|
||||||
|
|
||||||
boost::shared_ptr<Playlist>
|
boost::shared_ptr<Playlist>
|
||||||
Playlist::cut_copy (boost::shared_ptr<Playlist> (Playlist::*pmf)(framepos_t, framecnt_t,bool), list<AudioRange>& ranges, bool result_is_hidden)
|
Playlist::cut_copy (boost::shared_ptr<Playlist> (Playlist::*pmf)(framepos_t, framecnt_t,bool), list<AudioRange>& ranges, bool result_is_hidden)
|
||||||
{
|
{
|
||||||
boost::shared_ptr<Playlist> ret;
|
boost::shared_ptr<Playlist> ret;
|
||||||
boost::shared_ptr<Playlist> pl;
|
boost::shared_ptr<Playlist> pl;
|
||||||
framepos_t start;
|
framepos_t start;
|
||||||
@ -1165,25 +1165,25 @@ Playlist::flush_notifications (bool from_undo)
|
|||||||
}
|
}
|
||||||
|
|
||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
|
|
||||||
boost::shared_ptr<Playlist>
|
boost::shared_ptr<Playlist>
|
||||||
Playlist::cut (list<AudioRange>& ranges, bool result_is_hidden)
|
Playlist::cut (list<AudioRange>& ranges, bool result_is_hidden)
|
||||||
{
|
{
|
||||||
boost::shared_ptr<Playlist> (Playlist::*pmf)(framepos_t,framecnt_t,bool) = &Playlist::cut;
|
boost::shared_ptr<Playlist> (Playlist::*pmf)(framepos_t,framecnt_t,bool) = &Playlist::cut;
|
||||||
return cut_copy (pmf, ranges, result_is_hidden);
|
return cut_copy (pmf, ranges, result_is_hidden);
|
||||||
}
|
}
|
||||||
|
|
||||||
boost::shared_ptr<Playlist>
|
boost::shared_ptr<Playlist>
|
||||||
Playlist::copy (list<AudioRange>& ranges, bool result_is_hidden)
|
Playlist::copy (list<AudioRange>& ranges, bool result_is_hidden)
|
||||||
{
|
{
|
||||||
boost::shared_ptr<Playlist> (Playlist::*pmf)(framepos_t,framecnt_t,bool) = &Playlist::copy;
|
boost::shared_ptr<Playlist> (Playlist::*pmf)(framepos_t,framecnt_t,bool) = &Playlist::copy;
|
||||||
return cut_copy (pmf, ranges, result_is_hidden);
|
return cut_copy (pmf, ranges, result_is_hidden);
|
||||||
}
|
}
|
||||||
|
|
||||||
boost::shared_ptr<Playlist>
|
boost::shared_ptr<Playlist>
|
||||||
Playlist::cut (framepos_t start, framecnt_t cnt, bool result_is_hidden)
|
Playlist::cut (framepos_t start, framecnt_t cnt, bool result_is_hidden)
|
||||||
{
|
{
|
||||||
boost::shared_ptr<Playlist> the_copy;
|
boost::shared_ptr<Playlist> the_copy;
|
||||||
RegionList thawlist;
|
RegionList thawlist;
|
||||||
char buf[32];
|
char buf[32];
|
||||||
@ -1207,11 +1207,11 @@ Playlist::flush_notifications (bool from_undo)
|
|||||||
}
|
}
|
||||||
|
|
||||||
return the_copy;
|
return the_copy;
|
||||||
}
|
}
|
||||||
|
|
||||||
boost::shared_ptr<Playlist>
|
boost::shared_ptr<Playlist>
|
||||||
Playlist::copy (framepos_t start, framecnt_t cnt, bool result_is_hidden)
|
Playlist::copy (framepos_t start, framecnt_t cnt, bool result_is_hidden)
|
||||||
{
|
{
|
||||||
char buf[32];
|
char buf[32];
|
||||||
|
|
||||||
snprintf (buf, sizeof (buf), "%" PRIu32, ++subcnt);
|
snprintf (buf, sizeof (buf), "%" PRIu32, ++subcnt);
|
||||||
@ -1222,11 +1222,11 @@ Playlist::flush_notifications (bool from_undo)
|
|||||||
// cnt = min (_get_extent().second - start, cnt); (We need the full range length when copy/pasting in Ripple. Why was this limit here? It's not in CUT... )
|
// cnt = min (_get_extent().second - start, cnt); (We need the full range length when copy/pasting in Ripple. Why was this limit here? It's not in CUT... )
|
||||||
|
|
||||||
return PlaylistFactory::create (shared_from_this(), start, cnt, new_name, result_is_hidden);
|
return PlaylistFactory::create (shared_from_this(), start, cnt, new_name, result_is_hidden);
|
||||||
}
|
}
|
||||||
|
|
||||||
int
|
int
|
||||||
Playlist::paste (boost::shared_ptr<Playlist> other, framepos_t position, float times, const int32_t sub_num)
|
Playlist::paste (boost::shared_ptr<Playlist> other, framepos_t position, float times, const int32_t sub_num)
|
||||||
{
|
{
|
||||||
times = fabs (times);
|
times = fabs (times);
|
||||||
|
|
||||||
{
|
{
|
||||||
@ -1256,19 +1256,19 @@ Playlist::flush_notifications (bool from_undo)
|
|||||||
}
|
}
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
void
|
void
|
||||||
Playlist::duplicate (boost::shared_ptr<Region> region, framepos_t position, float times)
|
Playlist::duplicate (boost::shared_ptr<Region> region, framepos_t position, float times)
|
||||||
{
|
{
|
||||||
duplicate(region, position, region->length(), times);
|
duplicate(region, position, region->length(), times);
|
||||||
}
|
}
|
||||||
|
|
||||||
/** @param gap from the beginning of the region to the next beginning */
|
/** @param gap from the beginning of the region to the next beginning */
|
||||||
void
|
void
|
||||||
Playlist::duplicate (boost::shared_ptr<Region> region, framepos_t position, framecnt_t gap, float times)
|
Playlist::duplicate (boost::shared_ptr<Region> region, framepos_t position, framecnt_t gap, float times)
|
||||||
{
|
{
|
||||||
times = fabs (times);
|
times = fabs (times);
|
||||||
|
|
||||||
RegionWriteLock rl (this);
|
RegionWriteLock rl (this);
|
||||||
@ -1298,7 +1298,7 @@ Playlist::flush_notifications (bool from_undo)
|
|||||||
set_layer (sub, DBL_MAX);
|
set_layer (sub, DBL_MAX);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/** @param gap from the beginning of the region to the next beginning */
|
/** @param gap from the beginning of the region to the next beginning */
|
||||||
/** @param end the first frame that does _not_ contain a duplicated frame */
|
/** @param end the first frame that does _not_ contain a duplicated frame */
|
||||||
|
Loading…
Reference in New Issue
Block a user