godotengine / godot

Godot Engine – Multi-platform 2D and 3D game engine
https://godotengine.org
MIT License
88.44k stars 20.04k forks source link

The FileDialog > Create New Folder popup should also be exclusive and not hide if you click on it's parent FileDialog pane. #92848

Open wyattbiker opened 2 months ago

wyattbiker commented 2 months ago

Tested versions

System information

Linux Kubuntu 23.04 KDE Plasma Version: 5.27.4 KDE Frameworks Version: 5.104.0 Qt Version: 5.15.8

Issue description

When using the FileDialog node, the Create Folder popup should be forced to exclusive. If you click away by accident (e.g. inside the the FileDialog panel), the popup hides behind the FileDialog panel and cannot be recovered (unless you know to drag the FileDialog away to find it). In that case you need to force close the application.

image

Steps to reproduce

See reproduction attachment below.

Minimal reproduction project (MRP)

Archive.zip

wyattbiker commented 2 months ago

I wrote this function for now to fix the problem. It's specific to my issue but works. Can be modified to fix AcceptDialog as well.

fix_confirmations($SomeFD)  

func fix_confirmations(this: FileDialog):
    var node_list=this.get_children(true)   
    for node in node_list:
        if node.is_class("ConfirmationDialog"):
            node.always_on_top=true