Reputation: 819
Does anybody have a suggewstion to stop the scrollbox from raise a click event when you touch and drag to scroll it?
Scenario: I use a vertscrollbox with buttons as a scheduler on Android App, you can scroll up and down then click the buttons to show more information. The problem appear when you touch and scroll the screen, when letting go a click event is generated, if it's over a button you get the information but I don't want that unless you specifically click the button.
Hope my English is clear.
Upvotes: 0
Views: 954
Reputation: 507
You can use OnTap event. It is not a perfect solution because this event don't work on Windows (so you have to use conditional defines to debug on Windows), but on at least on Android OnTap isn't raised when you scroll a box (tested on Seattle).
Upvotes: 2
Reputation: 1
Make sure you check if the last event was the scrolling before execute the code in showmessage('OnCLick'). for this you have to keep a static variable with history of last event(s).
Upvotes: 0