How to invalidate ListView for new data when using ListAdapter
问题 I am making use of a default listview in a fragment to show data that is being called from a URL. There is a SwipeRefreshLayout where the ListView is contained. However when I refresh, the old data is still in the listview and the new data is just added at the top of the list. Is there a way to invalidate the old data? I have made use of a ListAdapter which is created from the SimpleAdapter class like so: ListAdapter adapter = new SimpleAdapter(getActivity(), newsItemList, R.layout.list_item,