diff options
author | Juan Linietsky <reduzio@gmail.com> | 2017-01-05 09:16:00 -0300 |
---|---|---|
committer | Juan Linietsky <reduzio@gmail.com> | 2017-01-05 09:16:00 -0300 |
commit | 0f7af4ea51744cda23c4d3c7481f9c332973d1d4 (patch) | |
tree | 27b8914062558b5648655ccf3db13251d217af98 /core/io/resource_format_binary.cpp | |
parent | 9e477babb3bf0ce5179395c2a5155a3f3cd36798 (diff) | |
download | redot-engine-0f7af4ea51744cda23c4d3c7481f9c332973d1d4.tar.gz |
-Changed most project settings in the engine, so they have major and minor categories.
-Changed SectionedPropertyEditor to support this
-Renamed Globals singleton to GlobalConfig, makes more sense.
-Changed the logic behind persisten global settings, instead of the persist checkbox, a revert button is now available
Diffstat (limited to 'core/io/resource_format_binary.cpp')
-rw-r--r-- | core/io/resource_format_binary.cpp | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/core/io/resource_format_binary.cpp b/core/io/resource_format_binary.cpp index 5328bb68fe..512031b128 100644 --- a/core/io/resource_format_binary.cpp +++ b/core/io/resource_format_binary.cpp @@ -355,7 +355,7 @@ Error ResourceInteractiveLoaderBinary::parse_variant(Variant& r_v) { if (path.find("://")==-1 && path.is_rel_path()) { // path is relative to file being loaded, so convert to a resource path - path=Globals::get_singleton()->localize_path(res_path.get_base_dir().plus_file(path)); + path=GlobalConfig::get_singleton()->localize_path(res_path.get_base_dir().plus_file(path)); } @@ -385,7 +385,7 @@ Error ResourceInteractiveLoaderBinary::parse_variant(Variant& r_v) { if (path.find("://")==-1 && path.is_rel_path()) { // path is relative to file being loaded, so convert to a resource path - path=Globals::get_singleton()->localize_path(res_path.get_base_dir().plus_file(path)); + path=GlobalConfig::get_singleton()->localize_path(res_path.get_base_dir().plus_file(path)); } @@ -1047,7 +1047,7 @@ Ref<ResourceInteractiveLoader> ResourceFormatLoaderBinary::load_interactive(cons } Ref<ResourceInteractiveLoaderBinary> ria = memnew( ResourceInteractiveLoaderBinary ); - ria->local_path=Globals::get_singleton()->localize_path(p_path); + ria->local_path=GlobalConfig::get_singleton()->localize_path(p_path); ria->res_path=ria->local_path; // ria->set_local_path( Globals::get_singleton()->localize_path(p_path) ); ria->open(f); @@ -1102,7 +1102,7 @@ Error ResourceFormatLoaderBinary::load_import_metadata(const String &p_path, Ref } Ref<ResourceInteractiveLoaderBinary> ria = memnew( ResourceInteractiveLoaderBinary ); - ria->local_path=Globals::get_singleton()->localize_path(p_path); + ria->local_path=GlobalConfig::get_singleton()->localize_path(p_path); ria->res_path=ria->local_path; // ria->set_local_path( Globals::get_singleton()->localize_path(p_path) ); ria->recognize(f); @@ -1147,7 +1147,7 @@ void ResourceFormatLoaderBinary::get_dependencies(const String& p_path,List<Stri ERR_FAIL_COND(!f); Ref<ResourceInteractiveLoaderBinary> ria = memnew( ResourceInteractiveLoaderBinary ); - ria->local_path=Globals::get_singleton()->localize_path(p_path); + ria->local_path=GlobalConfig::get_singleton()->localize_path(p_path); ria->res_path=ria->local_path; // ria->set_local_path( Globals::get_singleton()->localize_path(p_path) ); ria->get_dependencies(f,p_dependencies,p_add_types); @@ -1237,7 +1237,7 @@ Error ResourceFormatLoaderBinary::rename_dependencies(const String &p_path,const } Ref<ResourceInteractiveLoaderBinary> ria = memnew( ResourceInteractiveLoaderBinary ); - ria->local_path=Globals::get_singleton()->localize_path(p_path); + ria->local_path=GlobalConfig::get_singleton()->localize_path(p_path); ria->res_path=ria->local_path; ria->remaps=p_map; // ria->set_local_path( Globals::get_singleton()->localize_path(p_path) ); @@ -1372,7 +1372,7 @@ String ResourceFormatLoaderBinary::get_resource_type(const String &p_path) const } Ref<ResourceInteractiveLoaderBinary> ria = memnew( ResourceInteractiveLoaderBinary ); - ria->local_path=Globals::get_singleton()->localize_path(p_path); + ria->local_path=GlobalConfig::get_singleton()->localize_path(p_path); ria->res_path=ria->local_path; // ria->set_local_path( Globals::get_singleton()->localize_path(p_path) ); String r = ria->recognize(f); @@ -2192,7 +2192,7 @@ Error ResourceFormatSaverBinaryInstance::save(const String &p_path,const RES& p_ Error ResourceFormatSaverBinary::save(const String &p_path,const RES& p_resource,uint32_t p_flags) { - String local_path = Globals::get_singleton()->localize_path(p_path); + String local_path = GlobalConfig::get_singleton()->localize_path(p_path); ResourceFormatSaverBinaryInstance saver; return saver.save(local_path,p_resource,p_flags); |