Replace 'ERR_EXPLAIN' with 'ERR_FAIL_*_MSG' in 'core/' and 'editor/'
Condensed some if and ERR statements. Added dots to end of error messages Couldn't figure out EXPLAINC. These files gave me trouble: core/error_macros.h, core/io/file_access_buffered_fa.h (where is it?), core/os/memory.cpp, drivers/png/png_driver_common.cpp, drivers/xaudio2/audio_driver_xaudio2.cpp (where is it?)
This commit is contained in:
committed by
Rémi Verschelde
parent
40640a01dc
commit
71d71d55b5
@ -46,8 +46,7 @@ bool EditorResourcePreviewGenerator::handles(const String &p_type) const {
|
||||
if (get_script_instance() && get_script_instance()->has_method("handles")) {
|
||||
return get_script_instance()->call("handles", p_type);
|
||||
}
|
||||
ERR_EXPLAIN("EditorResourcePreviewGenerator::handles needs to be overridden");
|
||||
ERR_FAIL_V(false);
|
||||
ERR_FAIL_V_MSG(false, "EditorResourcePreviewGenerator::handles needs to be overridden.");
|
||||
}
|
||||
|
||||
Ref<Texture> EditorResourcePreviewGenerator::generate(const RES &p_from, const Size2 &p_size) const {
|
||||
@ -55,8 +54,7 @@ Ref<Texture> EditorResourcePreviewGenerator::generate(const RES &p_from, const S
|
||||
if (get_script_instance() && get_script_instance()->has_method("generate")) {
|
||||
return get_script_instance()->call("generate", p_from, p_size);
|
||||
}
|
||||
ERR_EXPLAIN("EditorResourcePreviewGenerator::generate needs to be overridden");
|
||||
ERR_FAIL_V(Ref<Texture>());
|
||||
ERR_FAIL_V_MSG(Ref<Texture>(), "EditorResourcePreviewGenerator::generate needs to be overridden.");
|
||||
}
|
||||
|
||||
Ref<Texture> EditorResourcePreviewGenerator::generate_from_path(const String &p_path, const Size2 &p_size) const {
|
||||
|
||||
Reference in New Issue
Block a user