summaryrefslogtreecommitdiff
path: root/gtk2_ardour/automation_line.cc
diff options
context:
space:
mode:
authorCarl Hetherington <carl@carlh.net>2010-08-20 22:43:10 +0000
committerCarl Hetherington <carl@carlh.net>2010-08-20 22:43:10 +0000
commit822ee79d840f20036b5729277f90e641cb0bb06f (patch)
tree404c5ce1e05c0b3fdca2473910974de5ddf9aed7 /gtk2_ardour/automation_line.cc
parentb2bf4eee3d9ca63a34415c75e877b8c97d6b5f13 (diff)
Limit region-based automation to the edges of regions. Fixes #3201.
git-svn-id: svn://localhost/ardour2/branches/3.0@7662 d708f5d6-7413-0410-9779-e7cbd77b26cf
Diffstat (limited to 'gtk2_ardour/automation_line.cc')
-rw-r--r--gtk2_ardour/automation_line.cc10
1 files changed, 10 insertions, 0 deletions
diff --git a/gtk2_ardour/automation_line.cc b/gtk2_ardour/automation_line.cc
index bf8b5c51b1..052691cb60 100644
--- a/gtk2_ardour/automation_line.cc
+++ b/gtk2_ardour/automation_line.cc
@@ -65,6 +65,7 @@ AutomationLine::AutomationLine (const string& name, TimeAxisView& tv, ArdourCanv
, alist (al)
, _parent_group (parent)
, _time_converter (converter ? (*converter) : default_converter)
+ , _maximum_time (max_frames)
{
points_visible = false;
update_pending = false;
@@ -1322,3 +1323,12 @@ AutomationLine::memento_command_binder ()
{
return new SimpleMementoCommandBinder<AutomationList> (*alist.get());
}
+
+/** Set the maximum time that points on this line can be at, relative
+ * to the start of the track or region that it is on.
+ */
+void
+AutomationLine::set_maximum_time (framepos_t t)
+{
+ _maximum_time = t;
+}