summaryrefslogtreecommitdiff
path: root/gtk2_ardour/automation_time_axis.cc
diff options
context:
space:
mode:
authorCarl Hetherington <carl@carlh.net>2010-08-06 23:28:44 +0000
committerCarl Hetherington <carl@carlh.net>2010-08-06 23:28:44 +0000
commitc06c6c153db6b33b93515100d839f376dc805d5d (patch)
treef550c01eed93591a6492e96c0b164033638ba864 /gtk2_ardour/automation_time_axis.cc
parentc333b19422c3cf0964ea09f5133b3222d85dd8eb (diff)
Fix up selection of automation points.
git-svn-id: svn://localhost/ardour2/branches/3.0@7556 d708f5d6-7413-0410-9779-e7cbd77b26cf
Diffstat (limited to 'gtk2_ardour/automation_time_axis.cc')
-rw-r--r--gtk2_ardour/automation_time_axis.cc13
1 files changed, 8 insertions, 5 deletions
diff --git a/gtk2_ardour/automation_time_axis.cc b/gtk2_ardour/automation_time_axis.cc
index 56a54c0092..b9edc4ef63 100644
--- a/gtk2_ardour/automation_time_axis.cc
+++ b/gtk2_ardour/automation_time_axis.cc
@@ -827,21 +827,23 @@ AutomationTimeAxisView::paste_one (AutomationLine& line, framepos_t pos, float t
}
void
-AutomationTimeAxisView::get_selectables (nframes_t start, nframes_t end, double top, double bot, list<Selectable*>& results)
+AutomationTimeAxisView::get_selectables (framepos_t start, framepos_t end, double top, double bot, list<Selectable*>& results)
{
if (!_line && !_view) {
return;
}
-
+
if (touched (top, bot)) {
- double topfrac;
- double botfrac;
/* remember: this is X Window - coordinate space starts in upper left and moves down.
_y_position is the "origin" or "top" of the track.
*/
- double mybot = _y_position + height;
+ /* bottom of our track */
+ double const mybot = _y_position + height;
+
+ double topfrac;
+ double botfrac;
if (_y_position >= top && mybot <= bot) {
@@ -858,6 +860,7 @@ AutomationTimeAxisView::get_selectables (nframes_t start, nframes_t end, double
topfrac = 1.0 - ((top - _y_position) / height);
botfrac = 1.0 - ((bot - _y_position) / height);
+
}
if (_line) {