on-internet
← Community

Alternative to set duplicateParentState to true for each child view?

Stack Overflow ·

Background I have a layout that has some special states (like being checked/pressed), and I wish to set its children to apply their own drawables based on this layout. i'm searching for an alternative of setting duplicateParentState to true for each of its children (and maybe even all of its descendants). What I've tried I've tried to make the custom view have an attribute of setting it to each of its children, but i couldn't find in which method call to apply this attribute to all of its children. in each method i've tried, it either returns 0 for getChildCount() or it just doesn't do anythin

Comments

Sign in or sign up to comment and upvote.

No comments yet.