Hi,
I have the following issue:
I have a TabGroupPane with several ContentPanes.Click AutoHIde on a given ContentPaneMouse over to bring up the ContentPane
At this step each TabGroupPane.Items become a ContentPanePlaceholder instead of ContentPane
Thing is that at a later step (when a ContentPane is closed) I have a code that given a ContentPane.Content (object) searchs for in the TabGroupPane.Items Collection and removes it . The ContentPlaceholder doesn't expose a public Pane property (however, it does have a private one), so problem is how can I remove the ContentPane from the original TabGroupPane.Items collection in this case.
Thanks,Claudio.
Thanks Andrew,
I now have the following code and it removes it also from the TabGroupPane.Items collection:
foreach (ContentPane contentPane in contentPanes) { if (e.OldItems.Contains(contentPane.Content)) { contentPane.Content = null; contentPane.CloseAction = PaneCloseAction.RemovePane; contentPane.ExecuteCommand(ContentPaneCommands.Close); } }
Is there anything else I am missing there ?
Thanks,Claudio
Currently the associated contentpane isn't exposed but if you're trying to remove a ContentPane completely from the XamDockManager (even if you're going to reinsert it), then you can set the PaneCloseAction to remove and use the Close command to close/remove the xamdockmanager. This will remove all the associated placeholders including any that may have been created for floating panes.