I have a border layout with a collapsible East panel. When I collapse the east panel it calls OnDetach. First of all I don't understand WHY would you want to detach children when doing Collapse. You can simply do a CSS hide/show. But anyway, as this is the case I want to somehow prevent the OnDetach when collapsing the panel. What is the best way to do that.

NOTE: I still want the collapse to take place though