aboutsummaryrefslogtreecommitdiffstats
path: root/java
diff options
context:
space:
mode:
authorTadashi G. Takaoka <takaoka@google.com>2014-10-02 07:54:31 +0000
committerAndroid Git Automerger <android-git-automerger@android.com>2014-10-02 07:54:31 +0000
commit0747228f1511534567a2512f14ff8aada65768c9 (patch)
tree8952369b00d059b861128e10edb3bada155935fe /java
parentf230b8f76a1f3583044c95afd52a006fe24d971a (diff)
parenta5cdd6f4c521acf84d8491757e2cc9181ad836e5 (diff)
downloadlatinime-0747228f1511534567a2512f14ff8aada65768c9.tar.gz
latinime-0747228f1511534567a2512f14ff8aada65768c9.tar.xz
latinime-0747228f1511534567a2512f14ff8aada65768c9.zip
am a5cdd6f4: Merge "Fix unnecessary touch event handling"
* commit 'a5cdd6f4c521acf84d8491757e2cc9181ad836e5': Fix unnecessary touch event handling
Diffstat (limited to 'java')
-rw-r--r--java/src/com/android/inputmethod/latin/suggestions/SuggestionStripView.java6
1 files changed, 6 insertions, 0 deletions
diff --git a/java/src/com/android/inputmethod/latin/suggestions/SuggestionStripView.java b/java/src/com/android/inputmethod/latin/suggestions/SuggestionStripView.java
index b421a7eb5..e40fd8800 100644
--- a/java/src/com/android/inputmethod/latin/suggestions/SuggestionStripView.java
+++ b/java/src/com/android/inputmethod/latin/suggestions/SuggestionStripView.java
@@ -400,6 +400,7 @@ public final class SuggestionStripView extends RelativeLayout implements OnClick
if (mStripVisibilityGroup.isShowingImportantNoticeStrip()) {
return false;
}
+ // Detecting sliding up finger to show {@link MoreSuggestionsView}.
if (!mMoreSuggestionsView.isShowingInParent()) {
mLastX = (int)me.getX();
mLastY = (int)me.getY();
@@ -439,6 +440,11 @@ public final class SuggestionStripView extends RelativeLayout implements OnClick
@Override
public boolean onTouchEvent(final MotionEvent me) {
+ if (!mMoreSuggestionsView.isShowingInParent()) {
+ // Ignore any touch event while more suggestions panel hasn't been shown.
+ // Detecting sliding up is done at {@link #onInterceptTouchEvent}.
+ return true;
+ }
// In the sliding input mode. {@link MotionEvent} should be forwarded to
// {@link MoreSuggestionsView}.
final int index = me.getActionIndex();