am 39511301: Fix crash in crop view
* commit '39511301a29f1965155e848c214dfa4bc3530722': Fix crash in crop view
This commit is contained in:
@@ -197,13 +197,14 @@ public class CropView extends TiledImageView implements OnScaleGestureListener {
|
||||
float squaredDist = (mFirstX - x) * (mFirstX - x) + (mFirstY - y) * (mFirstY - y);
|
||||
float slop = config.getScaledTouchSlop() * config.getScaledTouchSlop();
|
||||
long now = System.currentTimeMillis();
|
||||
// only do this if it's a small movement
|
||||
if (mTouchCallback != null &&
|
||||
squaredDist < slop &&
|
||||
now < mTouchDownTime + ViewConfiguration.getTapTimeout()) {
|
||||
mTouchCallback.onTap();
|
||||
if (mTouchCallback != null) {
|
||||
// only do this if it's a small movement
|
||||
if (squaredDist < slop &&
|
||||
now < mTouchDownTime + ViewConfiguration.getTapTimeout()) {
|
||||
mTouchCallback.onTap();
|
||||
}
|
||||
mTouchCallback.onTouchUp();
|
||||
}
|
||||
mTouchCallback.onTouchUp();
|
||||
}
|
||||
|
||||
if (!mTouchEnabled) {
|
||||
|
||||
Reference in New Issue
Block a user