Ghost windows when restoring layout with floating windows

Docking/MDI for Windows Forms Forum

Posted 13 years ago by Ernst
Avatar
There are nested dock managers in my application. When saving layout I do it for the main window's dock manager and then for all the next level dock managers.

This works fine until I try to float some of my MDI windows. In this case when restoring layout I get extra floating windows. I don't see them in the layout XML file. They are not in the m_dockManager.ToolWindows collection.

Please help,
Ernst

[Modified at 02/28/2007 02:11 PM]

Comments (3)

Posted 13 years ago by Actipro Software Support - Cleveland, OH, USA
Avatar
Could you put together a tiny sample project that shows this and e-mail it to us so we can see what is happening? Thanks!


Actipro Software Support

Posted 13 years ago by Ernst
Avatar
I'll have to get back to this later. For now I added a simple code which looks for such ghost windows and removes them after the layout is loaded. They are located under the real windows so user won't have a chance to see them.

May be you can think of some real fix, here is more details:

1) The ghost windows created for floating ToolWindows which used to be tabbed documents.
2) It only happens when at least one of these Tool Windows has its own Layout manager while loading both main layout and that Tool Window's layout.

I guess when user "floats" tabbed document ToolWindow you have to reparent all client controls so you create a new Form, move all controls into that form and hide the old parent. I suspect that this hidden old parent gets into layout and becomes visible when it is loaded.

Thanks,
Ernst
Posted 11 years ago by sijin lin
Avatar
I have the same problem and try to kill those ghost windows. Could you please tell me how you removed those ghost windows after loading layout? Your help is really appreciated.
-Sijin
The latest build of this product (v2020.1 build 0400) was released 6 days ago, which was after the last post in this thread.

Add Comment

Please log in to a validated account to post comments.