简体   繁体   中英

OnItemLongClick in Infinite Gallery

I am creating an Image gallery for my Android app and I need it to loop through images infinitely. To achieve this I am using the Infinite Gallery widget found here (Code is here ). The gallery works very well, however I am having trouble implementing a long press function. I am not trying to create a context menu, just trying to call another method.

Adding an onItemClickListener to the InfiniteGallery object in InfiniteGalleryActivity has not worked.

Have you tried with the GestureDetector.OnGestureListener, implementing the onLongPress(MotionEvent e)??

Information right here: http://developer.android.com/reference/android/view/GestureDetector.OnGestureListener.html

Hope this helps you out =)

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM