java - How to Reuse BaseAdapter view for multiple lists -


i have baseadapter list view takes list<objects> , reuse different lists. how go this?

you can create new instance each listview need.

for example, suppose have baseadapter called myadapter , 2 listviews.

myadapter myfirstadapter = new myadapter(objects); myfirstlistview.setadapter(myfirstadapter);  myadapter mysecondadapter = new myadapter(objects); mysecondlistview.setadapter(mysecondadapter); 

you should not use same adapter instance different listview, can use same class distinct instance.


Comments

Popular posts from this blog

javascript - AngularJS custom datepicker directive -

javascript - jQuery date picker - Disable dates after the selection from the first date picker -