• Which the release of FS2020 we see an explosition of activity on the forun and of course we are very happy to see this. But having all questions about FS2020 in one forum becomes a bit messy. So therefore we would like to ask you all to use the following guidelines when posting your questions:

    • Tag FS2020 specific questions with the MSFS2020 tag.
    • Questions about making 3D assets can be posted in the 3D asset design forum. Either post them in the subforum of the modelling tool you use or in the general forum if they are general.
    • Questions about aircraft design can be posted in the Aircraft design forum
    • Questions about airport design can be posted in the FS2020 airport design forum. Once airport development tools have been updated for FS2020 you can post tool speciifc questions in the subforums of those tools as well of course.
    • Questions about terrain design can be posted in the FS2020 terrain design forum.
    • Questions about SimConnect can be posted in the SimConnect forum.

    Any other question that is not specific to an aspect of development or tool can be posted in the General chat forum.

    By following these guidelines we make sure that the forums remain easy to read for everybody and also that the right people can find your post to answer it.

Undock panel window

Messages
531
Country
france
Do you know a way of undocking a panel window through a piece of code?
I know it can be done manually by right-clicking the window and click "undock window", but I would like to do it automatically with a module for fs9 and FSX that I am developing.

Thanks for any help,
Eric
 
2D panel window, XML, FSX-P3Dv4

Old thread. No answers so far but it's worth another shot.

Any way for a 2D window to be loaded in an undocked state, or an XML way to undock it without using right mouse click?

Thx

Bob
 
Opening a sub-window is easy, but I have never found any command that will auto-undock a sub-window... :(

Code:
PanelID# (>K:PANEL_ID_TOGGLE)
 
Last edited:
Panel windows are in fact Windows windows, with a very particular set of properties. I recall trying to change said properties programmatically a few years ago, with absolutely zero success.
 
I actually have another idea, which I will put on my ever increasing list of R&D topics.
 
There is solution on C++.

First, enum all windows to find correct panel's window's handles.

Code:
...
EnumWindows(SYSTEMS_EnumWindowsProc, NULL);
...

When you get correct panel window HWND, just send appropriate command:

Code:
// menu identifier "Undock Window" magic number is
// FS9 - 513
// P3D - 1025
for (all window handles in stored array)
     SendMessage(hPanelWindowHandles[i], WM_COMMAND, sim == sysSimFS9 ? 513 : 1025, 0);

This code I use in my utilite, which undock simulator panels, setting correct position in multi-monitor configurations, removes border and caption, and maximized them (to avoid accidental move from user).
 
Last edited:
There is solution on C++.
...
This code I use in my utilite, which undock simulator panels, setting correct position in multi-monitor configurations, removes border and caption, and maximized them (to avoid accidental move from user).
Thanks for posting this. It looks intriguing.
 
Back
Top