Makes the file browser window behave as follows:
- Always on top of its parent Blender window, but not on top of non-Blender windows.
- Minimize with its parent window
- Can be moved independently
- Doesn't add an own item in task bars
- Doesn't block other Blender windows (we may want to have this though)
- Open as floating window for tiling window managers (e.g. i3wm/Sway)
As this introduces a new kind of temporary window we have to take care
they don't conflict with each other. E.g. a Preferences window should not
become a dialog file browser window, and vice versa. I made it so that a
new window is opened if we try to open a dialog in a regular temporary
window, or the other way around.
This has the nice side effect that the file browser doesn't steal the
preferences window anymore, which was planned to be fixed anyway (see
T69652)
There are some differences between Windows and Linux (can't tell for
macOS), I'd like to have them as similar as possible though. Some more
things to note:
- Temporary windows don't stay on top of all Blender windows, only on top of its parent window (the one it was created in).
- When opening a file browser from the Preference window (or any temporary window), the main window, as the file browsers parent is moved on top of the Preferences, which makes it seem like it was closed. This is the general issue of bad secondary window handling as window activation changes. I made it so that the window is moved back once the file browser is closed.
- On Linux the temporary windows don't allow minimizing and maximizing. GTK and Qt have the same issue (if we consider it one).
- I disabled minimizing on Windows, otherwise minimizing does this:
- I left in some code for embedded child windows, but we don't use it (was for game engine). I'd suggest getting rid of it first (GHOST_TEmbedderWindowID).
Not sure how ready the macOS implementation is (or if it works at all).