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
Post a Comment