views:

5

answers:

0

Hi, I am making a collapsible ContentControl. Everything works fine until I try to embed a collapsible ContentControl as content inside the ContentPresenter of the same type collapsible control. The collapsing and expanding is done using animations. But when the content of the collapsible control changes in size it will not update its parent(s) resulting in area's not visible or other visual flaws. I looked everywhere, but I cannot seem to find a way to access the content inside the ContentPresenter to be able to update the parent(s) about their content size changes. The VisualTreeHelper doesn’t seem to help me here. If I look at the Panel, we can add Children as content there. I hope you could help me provide a similar approach for my collapsible ContentControl. Thanks in advance. With kind regards, Magiel