I have a list view with a list of items (To do), and 开发者_运维知识库I was wondering if there is a way to strike out the text, or entire box, when it is clicked?
Thanks
On a click (e.g., in onListItemClick()
of a ListActivity
), update your data model to reflect the fact that the to-do item is completed, then call notifyDataSetChanged()
on your Adapter
, to trigger the ListView
to update. In your custom Adapter
, format the rows as appropriate based upon your data model.
精彩评论