Highlight child in custom ExapandableListAdapter- Android
Just a quick question. I've created a custom ExpandableListAdapt开发者_如何转开发er, both the parent and child have it's own XML layout file. But it's lost the highlight option when you select it (obviously it still selects the row). What option do I need to set to make it highlight like the standard layout would.
Thanks!
The problem may be because of complex focus relationship between parent and its child. Try to disable child to be focusable like this:
parent.setDescendantFocusability(ViewGroup.FOCUS_BLOCK_DESCENDANTS);
精彩评论