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)

Était-ce utile?

La 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

Autres conseils

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

Licencié sous: CC-BY-SA avec attribution
Non affilié à StackOverflow
scroll top