Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to know which list item is visible to user?

I recorded videos through my app,And i stored in memory card.

After i get those videos and added to list view .

Based on screen size only one video is visible to user.

If user scroll up and down and stop.

At that point i want to know which one is in front of user.

If any one know the solution please help me.or any other way to do

Thanks in advance

like image 654
kiran Avatar asked Feb 02 '26 04:02

kiran


1 Answers

OK, there are two methods could help you.

ListView.getFirstVisiblePosition()
ListView.getLastVisiblePosition()

Look this page for details.

like image 193
faylon Avatar answered Feb 04 '26 01:02

faylon



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!