From b66f6c72c379d00e09de714a5c4aaef995ba82b8 Mon Sep 17 00:00:00 2001 From: alex Date: Wed, 21 Feb 2018 13:23:26 +0200 Subject: [PATCH] Call onClick() after ACTION_UP; invalidate view after setting background --- .../plus/mapmarkers/CoordinateInputDialogFragment.java | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/OsmAnd/src/net/osmand/plus/mapmarkers/CoordinateInputDialogFragment.java b/OsmAnd/src/net/osmand/plus/mapmarkers/CoordinateInputDialogFragment.java index 09f4dbf9cd..f6875ca1a1 100644 --- a/OsmAnd/src/net/osmand/plus/mapmarkers/CoordinateInputDialogFragment.java +++ b/OsmAnd/src/net/osmand/plus/mapmarkers/CoordinateInputDialogFragment.java @@ -960,12 +960,13 @@ public class CoordinateInputDialogFragment extends DialogFragment implements Osm int action = event.getAction(); if (action == MotionEvent.ACTION_DOWN) { v.setBackgroundColor(getResolvedColor(R.color.keyboard_item_bg_pressed)); - if (listener != null) { - listener.onClick(v); - } + v.invalidate(); return true; } setNormalBackground(v, controlButton); + if (listener != null) { + listener.onClick(v); + } return false; } });