From 6ffe1fff2df61a0b6648eea673bd693ea60c85ef Mon Sep 17 00:00:00 2001 From: Julian Murgia - StraToN Date: Fri, 4 Dec 2015 19:29:27 +0100 Subject: [PATCH] Set default destination filename of imported font to be input font filename if destination filename was ".fnt" (ie. no filename set by user) --- tools/editor/io_plugins/editor_font_import_plugin.cpp | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/tools/editor/io_plugins/editor_font_import_plugin.cpp b/tools/editor/io_plugins/editor_font_import_plugin.cpp index 10a3877529..5ba0669f1d 100644 --- a/tools/editor/io_plugins/editor_font_import_plugin.cpp +++ b/tools/editor/io_plugins/editor_font_import_plugin.cpp @@ -520,6 +520,10 @@ class EditorFontImportDialog : public ConfirmationDialog { return; } + if (dest->get_line_edit()->get_text().get_file()==".fnt") { + dest->get_line_edit()->set_text(dest->get_line_edit()->get_text().get_base_dir() + "/" + source->get_line_edit()->get_text().get_file().basename() + ".fnt" ); + } + Ref rimd = get_rimd(); if (rimd.is_null()) {