зеркало из https://github.com/mozilla/gecko-dev.git
Bug 705505 - Extend panzoom threshold. r=kats
This commit is contained in:
Родитель
d2b1f74489
Коммит
0a63e02a8c
|
@ -83,8 +83,8 @@ public class PanZoomController
|
|||
// values make the animation more accurate, but slower to plot.
|
||||
private static final int SUBDIVISION_COUNT = 1000;
|
||||
// The distance the user has to pan before we recognize it as such (e.g. to avoid
|
||||
// 1-pixel pans between the touch-down and touch-up of a click)
|
||||
private static final float PAN_THRESHOLD = 4.0f;
|
||||
// 1-pixel pans between the touch-down and touch-up of a click). In units of inches.
|
||||
private static final float PAN_THRESHOLD = 0.1f;
|
||||
// Angle from axis within which we stay axis-locked
|
||||
private static final double AXIS_LOCK_ANGLE = Math.PI / 6.0; // 30 degrees
|
||||
// The maximum velocity change factor between events, per ms, in %.
|
||||
|
@ -179,7 +179,7 @@ public class PanZoomController
|
|||
Log.e(LOGTAG, "Received impossible touch move while in " + mState);
|
||||
return false;
|
||||
case TOUCHING:
|
||||
if (panDistance(event) < PAN_THRESHOLD)
|
||||
if (panDistance(event) < PAN_THRESHOLD * GeckoAppShell.getDpi())
|
||||
return false;
|
||||
// fall through
|
||||
case PANNING_HOLD_LOCKED:
|
||||
|
|
Загрузка…
Ссылка в новой задаче