From 404f6a5726e79ca7b4b359bd1d77096c1f3e981c Mon Sep 17 00:00:00 2001 From: Helium314 Date: Mon, 2 Sep 2024 21:08:37 +0200 Subject: [PATCH] actually use downEvent detection, fixes #1075 --- .../keyboard/latin/suggestions/SuggestionStripView.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/src/main/java/helium314/keyboard/latin/suggestions/SuggestionStripView.java b/app/src/main/java/helium314/keyboard/latin/suggestions/SuggestionStripView.java index 6eef4c8d2..e105eade6 100644 --- a/app/src/main/java/helium314/keyboard/latin/suggestions/SuggestionStripView.java +++ b/app/src/main/java/helium314/keyboard/latin/suggestions/SuggestionStripView.java @@ -408,7 +408,7 @@ public final class SuggestionStripView extends RelativeLayout implements OnClick wordView.setEllipsize(TextUtils.TruncateAt.END); AtomicBoolean downOk = new AtomicBoolean(false); wordView.setOnTouchListener((view1, motionEvent) -> { - if (motionEvent.getAction() == MotionEvent.ACTION_UP) { + if (motionEvent.getAction() == MotionEvent.ACTION_UP && downOk.get()) { final float x = motionEvent.getX(); final float y = motionEvent.getY(); if (0 < x && x < w && 0 < y && y < h) {