Use new XDG folders to dehardcode paths

This commit is contained in:
Rémi Verschelde 2017-11-17 21:48:24 +01:00
parent 32c12a92a5
commit 6e3f2f44af
15 changed files with 58 additions and 61 deletions

View file

@ -128,7 +128,7 @@ void ScriptCreateDialog::_template_changed(int p_template) {
}
String ext = ScriptServer::get_language(language_menu->get_selected())->get_extension();
String name = template_list[p_template - 1] + "." + ext;
script_template = EditorSettings::get_singleton()->get_settings_dir() + "/script_templates/" + name;
script_template = EditorSettings::get_singleton()->get_script_templates_dir().plus_file(name);
}
void ScriptCreateDialog::ok_pressed() {