mirror of
https://github.com/Ardour/ardour.git
synced 2025-12-23 23:17:46 +01:00
move threshold for drags goes back to pair<int,int>
And for now, there's only a single implementation, though other types of drags could implement it if needed. There really seems to be no need. Note that the x-axis threshold is 3x in the case of a copy-drag.
This commit is contained in:
parent
f34e314d93
commit
1efd0c06bd
2 changed files with 14 additions and 30 deletions
|
|
@ -309,6 +309,16 @@ Drag::~Drag ()
|
|||
DEBUG_TRACE (DEBUG::Drags, "drag destroyed\n");
|
||||
}
|
||||
|
||||
Drag::MoveThreshold
|
||||
Drag::move_threshold () const
|
||||
{
|
||||
int basic_pixels = 4;
|
||||
int x = _copy ? basic_pixels * 3 : basic_pixels;
|
||||
int y = basic_pixels;
|
||||
|
||||
return std::make_pair (x, y);
|
||||
}
|
||||
|
||||
void
|
||||
Drag::set_time_domain (Temporal::TimeDomain td)
|
||||
{
|
||||
|
|
@ -504,7 +514,7 @@ Drag::motion_handler (GdkEvent* event, bool from_autoscroll)
|
|||
return false;
|
||||
}
|
||||
|
||||
pair<timecnt_t, int> const threshold = move_threshold ();
|
||||
MoveThreshold const threshold = move_threshold ();
|
||||
|
||||
bool const old_move_threshold_passed = _move_threshold_passed;
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue