Merge pull request #17442 from Noshyaar/esr

EditorNode: fix clicking ok keeps trying to save
This commit is contained in:
Rémi Verschelde 2018-03-13 09:36:55 +01:00 committed by GitHub
commit 15626fa2d0
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 3 additions and 0 deletions

View File

@ -597,6 +597,7 @@ void EditorNode::save_resource_in_path(const Ref<Resource> &p_resource, const St
Error err = ResourceSaver::save(path, p_resource, flg | ResourceSaver::FLAG_REPLACE_SUBRESOURCE_PATHS);
if (err != OK) {
current_option = -1;
accept->set_text(TTR("Error saving resource!"));
accept->popup_centered_minsize();
return;
@ -1194,6 +1195,7 @@ void EditorNode::_dialog_action(String p_file) {
Error err = ResourceSaver::save(p_file, ml);
if (err) {
current_option = -1;
accept->get_ok()->set_text(TTR("I see.."));
accept->set_text(TTR("Error saving MeshLibrary!"));
accept->popup_centered_minsize();
@ -1228,6 +1230,7 @@ void EditorNode::_dialog_action(String p_file) {
Error err = ResourceSaver::save(p_file, ml);
if (err) {
current_option = -1;
accept->get_ok()->set_text(TTR("I see.."));
accept->set_text(TTR("Error saving TileSet!"));
accept->popup_centered_minsize();