Question

I have a page in my app where the user can see a news feed (mostly images). How do I display these images (Using a LinearLayout maybe?)? And if so, how do I dynamically increase the size of this scrollable layout as I am scrolling down? (To load more images)

Was it helpful?

Solution

You have to use ListView. From the doc:

A view that shows items in a vertically scrolling list.

you have to provide a ListAdapter to your ListView. Basically the apdater is what fills up the ListView. It is higly customizable. You can simply pass to the adapter your data set or extend the adapter and customize the getView method in order to get the data rapresentation you want.

a tutorial can be found here

OTHER TIPS

Yes you have to use listview, just add the content and notify the adapter.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top