Reduce long press timeout on edge back gesture
Bug: 135625346 Test: Long press on side Change-Id: I88280f12acef054ba703e4a2a7a0234962f90045
This commit is contained in:
committed by
Jorim Jaggi
parent
544e00d382
commit
05d4be3601
@@ -66,6 +66,7 @@ import java.util.concurrent.Executor;
|
||||
public class EdgeBackGestureHandler implements DisplayListener {
|
||||
|
||||
private static final String TAG = "EdgeBackGestureHandler";
|
||||
private static final int MAX_LONG_PRESS_TIMEOUT = 250;
|
||||
|
||||
private final IPinnedStackListener.Stub mImeChangedListener = new IPinnedStackListener.Stub() {
|
||||
@Override
|
||||
@@ -168,7 +169,8 @@ public class EdgeBackGestureHandler implements DisplayListener {
|
||||
// before the app starts to react to it.
|
||||
// TODO(b/130352502) Tune this value and extract into a constant
|
||||
mTouchSlop = ViewConfiguration.get(context).getScaledTouchSlop() * 0.75f;
|
||||
mLongPressTimeout = ViewConfiguration.getLongPressTimeout();
|
||||
mLongPressTimeout = Math.min(MAX_LONG_PRESS_TIMEOUT,
|
||||
ViewConfiguration.getLongPressTimeout());
|
||||
|
||||
mNavBarHeight = res.getDimensionPixelSize(R.dimen.navigation_bar_frame_height);
|
||||
mMinArrowPosition = res.getDimensionPixelSize(R.dimen.navigation_edge_arrow_min_y);
|
||||
|
||||
Reference in New Issue
Block a user