Hello,
I want to close the Panes, and not just Hide them (put them in the ClosedPanes collection).
There is no CloseAction property on Pane, so how can i accomplish that?
I want to release the memory as the dynamically created documents/toolwindows are closed.
Thank you in advance,
Michael
Hi,
i downloaded the sample and i reproduced it like this... (did not make any change...)
1)Docked "DCH 1" window to the left.
2)Docked "DCH 2" window below "DCH 1"
3)Close them... They will become floating...
PS
Sorry, what i meant was that by resetting the IsPinned and IsFloating flag, it worked as expected
Hi Michael,
I couldn't understand what you mean by this:
Indeed the unpinned and floating panes do not go to the XamDockManager collections' by unsetting the corresponding flag...
I am attaching my testing solution in which I was not able to reproduce the issue you've described.Could you take a look and modify it so I could be able to check it out.
Regards,
Hi Konstantin,
The other issue still exists... here is what i do to show the panes dynamically and how to reproduce it...
For docking panel
1)I find tabgrouppane to the dock location of the xamdockmanager (if one does not exist i create it and dock it)
2)I add the pane to previous tabgrouppane.
3)Then i add another pane to the same dock location,so i find the previous tabgrouppane and add it to it's pane collection.
4)Move the second pane and dock it behind the first one.
5)Close the first one.
6)Try to close the second one. It will become floating, and then it won't close....
could you try the following:
void igXamDockManager_PaneClosing(object sender, CancellablePaneEventArgs e) { e.Cancel = true; ContentPane cPane = e.Pane as ContentPane; if (e.Pane.IsFloating == true) e.Pane.IsFloating = false; if (cPane != null && cPane.IsPinned == false) { cPane.IsPinned = true; } if (this.igXamDockManager.Panes.Contains(e.Pane)) { this.igXamDockManager.Panes.Remove(e.Pane); return; } else if (e.Pane.OwnerPane is TabGroupPane) (e.Pane.OwnerPane as TabGroupPane).Panes.Remove(e.Pane as ContentPane); else if (e.Pane.OwnerPane is SplitPane) (e.Pane.OwnerPane as SplitPane).Panes.Remove(e.Pane); }
I think that this might work for you.
I couldn't manage to reproduce this behavior
redbyron said: 1) When i close a ContentPane which is in a split container, The Pane becomes floating window
1) When i close a ContentPane which is in a split container, The Pane becomes floating window
However we have found a memory leak(about 420 B for a pane) which wont let the removed panes to be collected in some cases. We are targeting to fix this issue in August SR(the one after the upcoming one).
Please let me know if this does not resolves your issue completely or you need any further assistance.
thank you for your help and for taking into considatarion my proposal.
But I would also need a workaround for one of the two methods mentioned in the previous posts, 1) handle the closing event or 2) Recycling closed panes ....
I have an application that uses a dock manager control from another vendor, because you did not provide one.. Now that you launched XamDockManager, i want to replace the existing control with yours, without loosing functionality or gaining many bugs/problems....