Dirkster99 / AvalonDock

Our own development branch of the well known WPF document docking library

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

How to keep order of LayoutAnchorable after setting IsVisible

xiazeyi opened this issue · comments

Given several LayoutAnchorables in LayoutDocumentPane (Using laOne, laTwo, laThree to represent them), the original order of them is: laOne, laTwo, laThree.
Set their IsVisible to False one by one from laOne to laThree, they are all hidden.
Then set their IsVisible to True one by one from laOne to laThree, they are all shown, but the order is changed to: laThree, laTwo, laOne.
Their PreviousContainerIndex is all 0 after they are hidden one by one, as a result the order is changed after inserting them back to LayoutDocumentPane to show them.
Is there a way to keep the order of them, such as ordering by ContentId?
Thanks.

I can fix it by specifying a customized DockingManager.LayoutUpdateStrategy, but same issue happens after floating them one by one and then docking them back.