summaryrefslogtreecommitdiff
path: root/gtk2_ardour/automation_line.cc
diff options
context:
space:
mode:
authorRobin Gareus <robin@gareus.org>2017-06-19 12:33:43 +0200
committerRobin Gareus <robin@gareus.org>2017-06-21 18:12:16 +0200
commit555fcb89e541a8aaf1beb3df234e60569a667876 (patch)
treed8997206cbea82d2a9f9da88f272ba4a15b108a3 /gtk2_ardour/automation_line.cc
parentfe83e1e2ed450814dfec0ffed7a2c2559c6fa8b6 (diff)
GUI: prepare for API changes
remove use of - unbound_min/max - list->default_value and min/max_y
Diffstat (limited to 'gtk2_ardour/automation_line.cc')
-rw-r--r--gtk2_ardour/automation_line.cc4
1 files changed, 2 insertions, 2 deletions
diff --git a/gtk2_ardour/automation_line.cc b/gtk2_ardour/automation_line.cc
index 98b87ee6e6..388d817c39 100644
--- a/gtk2_ardour/automation_line.cc
+++ b/gtk2_ardour/automation_line.cc
@@ -1225,7 +1225,7 @@ AutomationLine::view_to_model_coord_y (double& y) const
y = max ((double) _desc.lower, y);
y = min ((double) _desc.upper, y);
} else {
- y = y * (double)(alist->get_max_y() - alist->get_min_y()) + alist->get_min_y();
+ y = y * (double)(_desc.upper - _desc.lower) + _desc.lower;
if (_desc.integer_step) {
y = round(y);
} else if (_desc.toggled) {
@@ -1255,7 +1255,7 @@ AutomationLine::model_to_view_coord_y (double& y) const
} else if (alist->parameter().type() == PanWidthAutomation) {
y = .5 + y * .5;
} else {
- y = (y - alist->get_min_y()) / (double)(alist->get_max_y() - alist->get_min_y());
+ y = (y - _desc.lower) / (double)(_desc.upper - _desc.lower);
}
}