ListView Item is not clickable in Android

前端 未结 4 1206
说谎
说谎 2020-12-16 04:09

In this ListView is not clickable, I want to perform an action on item click but I do not know why this is not clickable, I have also checked in debugging the controller is

相关标签:
4条回答
  • 2020-12-16 04:52

    Ok you have a button in there. In your list_item xml put android:descendantFocusability="blocksDescendants" in the LinearLayout or RelativeLayout you have.

    0 讨论(0)
  • 2020-12-16 04:56

    just remove

    listshowcase.setClickable(true);
    

    this line from ShowCases. And then try again.

    I hope this will help you. If not please let me know.

    0 讨论(0)
  • 2020-12-16 05:01

    add an OnClickListener to each of your views returned from your adapter.

    0 讨论(0)
  • 2020-12-16 05:06

    Are you able to display list? If yes then please show that layout file holding TextView to display item in list.

    Try removing isTextSelectable from that TextView in that case.

    Check if there is some silly mistake like I made few months ago from here:

    onItemClick in ListView doesn't work

    0 讨论(0)
提交回复
热议问题