Fix implementation of Drag::adjusted_time() to behave like the pre-nutempo version
This commit is contained in:
parent
5ee2c91864
commit
3a1d8c48df
|
@ -368,14 +368,15 @@ Drag::end_grab (GdkEvent* event)
|
||||||
timepos_t
|
timepos_t
|
||||||
Drag::adjusted_time (timepos_t const & f, GdkEvent const * event, bool snap) const
|
Drag::adjusted_time (timepos_t const & f, GdkEvent const * event, bool snap) const
|
||||||
{
|
{
|
||||||
timepos_t pos (f);
|
timepos_t pos (f.time_domain()); /* zero */
|
||||||
|
|
||||||
if (f > _pointer_offset) {
|
if (f > _pointer_offset) {
|
||||||
pos.shift_earlier (_pointer_offset);
|
pos = timepos_t (_pointer_offset).distance (f);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (snap) {
|
if (snap) {
|
||||||
_editor->snap_to_with_modifier (pos, event);
|
_editor->snap_to_with_modifier (pos, event);
|
||||||
|
cerr << pos << endl;
|
||||||
}
|
}
|
||||||
|
|
||||||
return pos;
|
return pos;
|
||||||
|
|
Loading…
Reference in New Issue
Block a user