OnItemClickListener on a ListView inside a Fragment not working

后端 未结 7 1503
粉色の甜心
粉色の甜心 2020-12-29 09:11

EDIT: SOLVED. If there\'s anything focusable in the XML of the items, it will break the touch of the list, in other words, android:focusable=false to all the checkbo

7条回答
  •  误落风尘
    2020-12-29 09:36

    Here is an overview of the workflow, create your ListView and it's corresponding Adapter(used to map your underlying data to the items in the ListView), set the adapter to the ListView, and then add an OnItemClickListener to it.

    More details and sample code can be found at: http://developer.android.com/guide/topics/ui/declaring-layout.html#AdapterViews

提交回复
热议问题