Minor simplification.

git-svn-id: svn://localhost/ardour2/branches/3.0@12059 d708f5d6-7413-0410-9779-e7cbd77b26cf
This commit is contained in:
Carl Hetherington 2012-04-23 00:35:38 +00:00
parent 8d94cc6d13
commit 8a98f466f9

View File

@ -2981,14 +2981,7 @@ LineDrag::motion (GdkEvent* event, bool)
cy = min ((double) _line->height(), cy);
double const fraction = 1.0 - (cy / _line->height());
bool push;
if (Keyboard::modifier_state_contains (event->button.state, Keyboard::PrimaryModifier)) {
push = false;
} else {
push = true;
}
bool const push = !Keyboard::modifier_state_contains (event->button.state, Keyboard::PrimaryModifier);
/* we are ignoring x position for this drag, so we can just pass in anything */
_line->drag_motion (0, fraction, true, push);