summaryrefslogtreecommitdiff
path: root/gtk2_ardour/region_selection.cc
diff options
context:
space:
mode:
authorDavid Robillard <d@drobilla.net>2006-08-29 21:21:48 +0000
committerDavid Robillard <d@drobilla.net>2006-08-29 21:21:48 +0000
commit82232f06ba3eea4a2b4342ad91fab552f4044402 (patch)
treed517cb47c017f51e2ecd9450624b86eb70d9f97b /gtk2_ardour/region_selection.cc
parent25d1670a61d19e795227b939a98be9cf5a050c67 (diff)
Merged with trunk R861
Possible new bugs - not very thoroughly tested, but at least functional at first glance git-svn-id: svn://localhost/ardour2/branches/midi@870 d708f5d6-7413-0410-9779-e7cbd77b26cf
Diffstat (limited to 'gtk2_ardour/region_selection.cc')
-rw-r--r--gtk2_ardour/region_selection.cc26
1 files changed, 13 insertions, 13 deletions
diff --git a/gtk2_ardour/region_selection.cc b/gtk2_ardour/region_selection.cc
index f8c9f384a9..7f7148d2b1 100644
--- a/gtk2_ardour/region_selection.cc
+++ b/gtk2_ardour/region_selection.cc
@@ -102,12 +102,12 @@ RegionSelection::add (RegionView* rv, bool dosort)
rv->RegionViewGoingAway.connect (mem_fun(*this, &RegionSelection::remove_it));
- if (rv->region().first_frame() < _current_start || empty()) {
- _current_start = rv->region().first_frame();
+ if (rv->region()->first_frame() < _current_start || empty()) {
+ _current_start = rv->region()->first_frame();
}
- if (rv->region().last_frame() > _current_end || empty()) {
- _current_end = rv->region().last_frame();
+ if (rv->region()->last_frame() > _current_end || empty()) {
+ _current_end = rv->region()->last_frame();
}
insert (rv);
@@ -142,17 +142,17 @@ RegionSelection::remove (RegionView* rv)
} else {
- Region& region ((*i)->region());
+ boost::shared_ptr<Region> region ((*i)->region());
- if (region.first_frame() == _current_start) {
+ if (region->first_frame() == _current_start) {
/* reset current start */
jack_nframes_t ref = max_frames;
for (i = begin (); i != end(); ++i) {
- if (region.first_frame() < ref) {
- ref = region.first_frame();
+ if (region->first_frame() < ref) {
+ ref = region->first_frame();
}
}
@@ -160,15 +160,15 @@ RegionSelection::remove (RegionView* rv)
}
- if (region.last_frame() == _current_end) {
+ if (region->last_frame() == _current_end) {
/* reset current end */
jack_nframes_t ref = 0;
for (i = begin (); i != end(); ++i) {
- if (region.first_frame() > ref) {
- ref = region.first_frame();
+ if (region->first_frame() > ref) {
+ ref = region->first_frame();
}
}
@@ -191,7 +191,7 @@ RegionSelection::add_to_layer (RegionView * rv)
for (i = _bylayer.begin(); i != _bylayer.end(); ++i)
{
- if (rv->region().layer() < (*i)->region().layer()) {
+ if (rv->region()->layer() < (*i)->region()->layer()) {
_bylayer.insert(i, rv);
return;
}
@@ -203,7 +203,7 @@ RegionSelection::add_to_layer (RegionView * rv)
struct RegionSortByTime {
bool operator() (const RegionView* a, const RegionView* b) {
- return a->region().position() < b->region().position();
+ return a->region()->position() < b->region()->position();
}
};