Implement a transient_to_focused mode

This intends to be the correct way to handle non-child windows becoming covered by the current window when becoming focused.
Enabling this property on select windows, they will become transient to the currently focused one when becoming visible.

This deprecates the "unparent_when_invisible" function introduced by #76025.
This commit is contained in:
Juan Linietsky 2023-12-22 17:50:21 +01:00
parent 13a0d6e9b2
commit 15144c24bd
12 changed files with 85 additions and 14 deletions

View file

@ -126,6 +126,7 @@ private:
bool use_font_oversampling = false;
bool transient = false;
bool transient_to_focused = false;
bool exclusive = false;
bool wrap_controls = false;
bool updating_child_controls = false;
@ -313,6 +314,9 @@ public:
void set_transient(bool p_transient);
bool is_transient() const;
void set_transient_to_focused(bool p_transient_to_focused);
bool is_transient_to_focused() const;
void set_exclusive(bool p_exclusive);
bool is_exclusive() const;