jMonkeyEngine-Contributions / Lemur

Lemur is a jMonkeyEngine-based UI toolkit.
http://jmonkeyengine-contributions.github.io/Lemur/
BSD 3-Clause "New" or "Revised" License
116 stars 32 forks source link

AndroidClickFix #35

Open ericbourque29 opened 8 years ago

ericbourque29 commented 8 years ago

Replaced UP and DOWN with TAP in the TouchObserver to avoid double events in adroid.

pspeed42 commented 5 years ago

Which double events? You should get an event when you press and an event when you release... just like any other key or button.

mrlem commented 4 years ago

I suspect what @ericbourque29 was referring to is that in Android, not only will up and down events be fired, but also a tap event.

However, the TouchObserver doesn't consume those, so they will be passed on to the scene behind your UI. And from your scene, if you want to react to tap events, you will receive them all regardless whether or not they landed in your UI first.

(faced the same issue myself).

mrlem commented 4 years ago

Personally, I'd still consume UP and DOWN events, but also TAP events.