summaryrefslogtreecommitdiff
path: root/scene/gui
diff options
context:
space:
mode:
authorNathan Warden <nathanwardenlee@icloud.com>2015-01-16 07:48:28 -0500
committerNathan Warden <nathanwardenlee@icloud.com>2015-01-16 07:48:28 -0500
commitcac555dc78047b96486d5c52e990c7dde62f0a6b (patch)
tree4cd0b8481a80021ce44048d139cc2513801b324a /scene/gui
parentc2ffdb05d4bffd75fd28fb791882c14ec6758b8c (diff)
When overwriting a file with an auto added extension the file name is now set correctly.
Diffstat (limited to 'scene/gui')
-rw-r--r--scene/gui/file_dialog.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/scene/gui/file_dialog.cpp b/scene/gui/file_dialog.cpp
index a98cb841dc..fbcfdb69bb 100644
--- a/scene/gui/file_dialog.cpp
+++ b/scene/gui/file_dialog.cpp
@@ -156,7 +156,6 @@ void FileDialog::_action_pressed() {
if (mode==MODE_SAVE_FILE) {
- String ext = f.extension();
bool valid=false;
if (filter->get_selected()==filter->get_item_count()-1) {
@@ -197,6 +196,7 @@ void FileDialog::_action_pressed() {
if (!valid && filterSliceCount>0) {
String str = (flt.get_slice(",",0).strip_edges());
f+=str.substr(1, str.length()-1);
+ file->set_text(f.get_file());
valid=true;
}
} else {