Android ExpandableListView Hide Group

I have an ExpandableListView, and the user can go into the application settings to determine which groups will be displayed in the list. How can I make a specific group not visible? I tried setVisibility (View.GONE) and this still leaves the space the group was in, as well as the group indicator.

Is it possible to make a group in my ExpandableListView not visible and not leave an empty place where it was?

Thanks!

+4
source share
1 answer

One solution may not be to change the view , in this case an ExpandableListView. Instead, consider the problem at the basic data level. For example, in each group there is an indicator indicating whether or not to include this group. And then show only the groups that have their own indicator of how to "show".

0
source

Source: https://habr.com/ru/post/1488510/


All Articles