You've already forked godot
mirror of
https://github.com/godotengine/godot.git
synced 2025-11-30 16:26:50 +00:00
Merge pull request #23673 from marcelofg55/export_path_3
Export Path now has a folder icon to select the path
This commit is contained in:
@@ -233,7 +233,7 @@ void EditorPropertyPath::_path_pressed() {
|
||||
dialog->set_mode(EditorFileDialog::MODE_OPEN_DIR);
|
||||
dialog->set_current_dir(full_path);
|
||||
} else {
|
||||
dialog->set_mode(EditorFileDialog::MODE_OPEN_FILE);
|
||||
dialog->set_mode(save_mode ? EditorFileDialog::MODE_SAVE_FILE : EditorFileDialog::MODE_OPEN_FILE);
|
||||
for (int i = 0; i < extensions.size(); i++) {
|
||||
String e = extensions[i].strip_edges();
|
||||
if (e != String()) {
|
||||
@@ -260,6 +260,11 @@ void EditorPropertyPath::setup(const Vector<String> &p_extensions, bool p_folder
|
||||
global = p_global;
|
||||
}
|
||||
|
||||
void EditorPropertyPath::set_save_mode() {
|
||||
|
||||
save_mode = true;
|
||||
}
|
||||
|
||||
void EditorPropertyPath::_notification(int p_what) {
|
||||
|
||||
if (p_what == NOTIFICATION_ENTER_TREE || p_what == NOTIFICATION_THEME_CHANGED) {
|
||||
@@ -296,6 +301,7 @@ EditorPropertyPath::EditorPropertyPath() {
|
||||
path_edit->connect("pressed", this, "_path_pressed");
|
||||
folder = false;
|
||||
global = false;
|
||||
save_mode = false;
|
||||
}
|
||||
|
||||
///////////////////// CLASS NAME /////////////////////////
|
||||
|
||||
Reference in New Issue
Block a user