LongClick timing too short

touchsquid

Active Member
Licensed User
Longtime User
In one of my apps there are Favorites buttons which are selected with a short click. A long click is used to redefine the favorite.

Some users with slow fingers complain that they get the long click when they meant to get a short click. Is there a way to increase the long click timing delay?
 

MiniDemonic

Member
Licensed User
Longtime User
I don't know if you can change the long click delay, but shouldn't you be able to use a timer to accomplish the same? Sure it's more code but it's an easy solution.
 
Upvote 0

nfordbscndrd

Well-Known Member
Licensed User
Longtime User
I use the routine below in one of my apps where it's easy to press the Okay button too fast. It might work for you. It doesn't require a timer, just a Global variable like LastOkayTime.

B4X:
Sub btnOkay_Click
   DateTime.DateFormat = "h:mm a"
   now = DateTime.now
   ' Stop accidental multiple presses of Okay button:
   If now - LastOkayTime < 200 Then 
      Return
   End If
   LastOkayTime = now
    ...
End Sub
 
Upvote 0
Top