Remove suspect pixel-based control point x position clamping; this may cause issues in libart, so may need reverting.
git-svn-id: svn://localhost/ardour2/branches/3.0@12504 d708f5d6-7413-0410-9779-e7cbd77b26cf
This commit is contained in:
parent
650f16620d
commit
d4af4d99e9
@ -495,30 +495,9 @@ AutomationLine::drag_motion (double x, float fraction, bool ignore_x, bool with_
|
||||
|
||||
/* clamp x */
|
||||
for (list<ControlPoint*>::iterator i = points.begin(); i != points.end(); ++i) {
|
||||
|
||||
if ((*i)->can_slide() && !ignore_x) {
|
||||
|
||||
/* clamp min x */
|
||||
double const a = (*i)->get_x() + dx;
|
||||
double const b = before_x + 1;
|
||||
if (a < b) {
|
||||
dx += b - a;
|
||||
}
|
||||
|
||||
/* clamp max x */
|
||||
if (after) {
|
||||
|
||||
if (after_x - before_x < 2) {
|
||||
/* after and before are very close, so just leave this alone */
|
||||
dx = 0;
|
||||
} else {
|
||||
double const a = (*i)->get_x() + dx;
|
||||
double const b = after_x - 1;
|
||||
if (a > b) {
|
||||
dx -= a - b;
|
||||
}
|
||||
}
|
||||
}
|
||||
x = max (x, before_x);
|
||||
x = min (x, after_x);
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user