Skip to content Skip to sidebar Skip to footer

Imagebutton Onlongpress Causes Onclick As Well

i have an application with an imagebutton that has both an onclick and an onlongclick listener. However, when the button is long pressed, both of these listeners are executing. A

Solution 1:

I think your problem has to do with the fact that you're returning false in your onLongClick method. Try returning true instead (despite the fact that you're canceling the long click, returning true is just saying "I've handled this, no further action is required.").


Post a Comment for "Imagebutton Onlongpress Causes Onclick As Well"