android: hide the keyboard when scrolling velocity exceeds 18

Change-Id: Ibc3c1e384e73f0ecdd10f5a0c8972a04e4101a59
This commit is contained in:
Tomaž Vajngerl
2015-04-13 19:25:09 +09:00
parent 98b12bf77f
commit 3c4fd27392

View File

@@ -274,6 +274,11 @@ public class JavaPanZoomController
}
private boolean handleTouchMove(MotionEvent event) {
if (mState == PanZoomState.PANNING_LOCKED || mState == PanZoomState.PANNING) {
if (getVelocity() > 18.0f) {
LibreOfficeMainActivity.mAppContext.hideSoftKeyboard();
}
}
switch (mState) {
case FLING:
@@ -418,7 +423,6 @@ public class JavaPanZoomController
} else {
setState(PanZoomState.PANNING);
}
//LibreOfficeMainActivity.mAppContext.hideSoftKeyboard();
}
private float panDistance(MotionEvent move) {