StringName: Fix empty hash

+Fixed compat hashes
This commit is contained in:
rune-scape 2024-09-04 20:11:06 -07:00
parent 27552a2f26
commit 0dde931bc9
19 changed files with 68 additions and 263 deletions

View File

@ -103,6 +103,14 @@ void GDExtensionCompatHashes::initialize() {
mappings.insert("AcceptDialog", { mappings.insert("AcceptDialog", {
{ "add_button", 4158837846, 3328440682 }, { "add_button", 4158837846, 3328440682 },
}); });
mappings.insert("AnimatedSprite2D", {
{ "play", 2372066587, 3269405555 },
{ "play_backwards", 1421762485, 3323268493 },
});
mappings.insert("AnimatedSprite3D", {
{ "play", 2372066587, 3269405555 },
{ "play_backwards", 1421762485, 3323268493 },
});
mappings.insert("Animation", { mappings.insert("Animation", {
{ "add_track", 2393815928, 3843682357 }, { "add_track", 2393815928, 3843682357 },
{ "track_insert_key", 1985425300, 808952278 }, { "track_insert_key", 1985425300, 808952278 },
@ -146,6 +154,12 @@ void GDExtensionCompatHashes::initialize() {
{ "travel", 3683006648, 3823612587 }, { "travel", 3683006648, 3823612587 },
{ "start", 3683006648, 3823612587 }, { "start", 3683006648, 3823612587 },
}); });
mappings.insert("AnimationPlayer", {
{ "play", 3697947785, 3118260607 },
{ "play", 2221377757, 3118260607 },
{ "play_backwards", 3890664824, 2787282401 },
{ "play_with_capture", 3180464118, 1572969103 },
});
mappings.insert("ArrayMesh", { mappings.insert("ArrayMesh", {
{ "add_surface_from_arrays", 172284304, 1796411378 }, { "add_surface_from_arrays", 172284304, 1796411378 },
}); });
@ -247,13 +261,20 @@ void GDExtensionCompatHashes::initialize() {
}); });
mappings.insert("DisplayServer", { mappings.insert("DisplayServer", {
{ "global_menu_add_submenu_item", 3806306913, 2828985934 }, { "global_menu_add_submenu_item", 3806306913, 2828985934 },
{ "global_menu_add_item", 3415468211, 3401266716 }, { "global_menu_add_item", 3415468211, 3616842746 },
{ "global_menu_add_check_item", 3415468211, 3401266716 }, { "global_menu_add_item", 3401266716, 3616842746 },
{ "global_menu_add_icon_item", 1700867534, 4245856523 }, { "global_menu_add_check_item", 3415468211, 3616842746 },
{ "global_menu_add_icon_check_item", 1700867534, 4245856523 }, { "global_menu_add_check_item", 3401266716, 3616842746 },
{ "global_menu_add_radio_check_item", 3415468211, 3401266716 }, { "global_menu_add_icon_item", 1700867534, 3867083847 },
{ "global_menu_add_icon_radio_check_item", 1700867534, 4245856523 }, { "global_menu_add_icon_item", 4245856523, 3867083847 },
{ "global_menu_add_multistate_item", 635750054, 3431222859 }, { "global_menu_add_icon_check_item", 1700867534, 3867083847 },
{ "global_menu_add_icon_check_item", 4245856523, 3867083847 },
{ "global_menu_add_radio_check_item", 3415468211, 3616842746 },
{ "global_menu_add_radio_check_item", 3401266716, 3616842746 },
{ "global_menu_add_icon_radio_check_item", 1700867534, 3867083847 },
{ "global_menu_add_icon_radio_check_item", 4245856523, 3867083847 },
{ "global_menu_add_multistate_item", 635750054, 3297554655 },
{ "global_menu_add_multistate_item", 3431222859, 3297554655 },
{ "global_menu_add_separator", 1041533178, 3214812433 }, { "global_menu_add_separator", 1041533178, 3214812433 },
{ "tts_speak", 3741216677, 903992738 }, { "tts_speak", 3741216677, 903992738 },
{ "is_touchscreen_available", 4162880507, 3323674545 }, { "is_touchscreen_available", 4162880507, 3323674545 },
@ -286,6 +307,12 @@ void GDExtensionCompatHashes::initialize() {
{ "virtual_keyboard_show", 860410478, 3042891259 }, { "virtual_keyboard_show", 860410478, 3042891259 },
#endif #endif
}); });
mappings.insert("EditorExportPlatform", {
{ "export_project_files", 425454869, 1063735070 },
});
mappings.insert("EditorProperty", {
{ "emit_changed", 3069422438, 1822500399 },
});
mappings.insert("ENetConnection", { mappings.insert("ENetConnection", {
{ "create_host_bound", 866250949, 1515002313 }, { "create_host_bound", 866250949, 1515002313 },
{ "connect_to_host", 385984708, 2171300490 }, { "connect_to_host", 385984708, 2171300490 },
@ -453,18 +480,35 @@ void GDExtensionCompatHashes::initialize() {
mappings.insert("MultiplayerAPI", { mappings.insert("MultiplayerAPI", {
{ "rpc", 1833408346, 2077486355 }, { "rpc", 1833408346, 2077486355 },
}); });
mappings.insert("NativeMenu", {
{ "add_item", 2553375659, 980552939 },
{ "add_check_item", 2553375659, 980552939 },
{ "add_icon_item", 2987595282, 1372188274 },
{ "add_icon_check_item", 2987595282, 1372188274 },
{ "add_radio_check_item", 2553375659, 980552939 },
{ "add_icon_radio_check_item", 2987595282, 1372188274 },
{ "add_multistate_item", 1558592568, 2674635658 },
});
mappings.insert("NavigationMeshGenerator", { mappings.insert("NavigationMeshGenerator", {
{ "parse_source_geometry_data", 3703028813, 685862123 }, { "parse_source_geometry_data", 3703028813, 3172802542 },
{ "bake_from_source_geometry_data", 3669016597, 2469318639 }, { "parse_source_geometry_data", 685862123, 3172802542 },
{ "bake_from_source_geometry_data", 3669016597, 1286748856 },
{ "bake_from_source_geometry_data", 2469318639, 1286748856 },
}); });
mappings.insert("NavigationServer2D", { mappings.insert("NavigationServer2D", {
{ "map_get_path", 56240621, 3146466012 }, { "map_get_path", 56240621, 3146466012 },
{ "parse_source_geometry_data", 1176164995, 1766905497 },
{ "bake_from_source_geometry_data", 2909414286, 2179660022 },
{ "bake_from_source_geometry_data_async", 2909414286, 2179660022 },
}); });
mappings.insert("NavigationServer3D", { mappings.insert("NavigationServer3D", {
{ "map_get_path", 2121045993, 1187418690 }, { "map_get_path", 2121045993, 1187418690 },
{ "parse_source_geometry_data", 3703028813, 685862123 }, { "parse_source_geometry_data", 3703028813, 3172802542 },
{ "bake_from_source_geometry_data", 3669016597, 2469318639 }, { "parse_source_geometry_data", 685862123, 3172802542 },
{ "bake_from_source_geometry_data_async", 3669016597, 2469318639 }, { "bake_from_source_geometry_data", 3669016597, 1286748856 },
{ "bake_from_source_geometry_data", 2469318639, 1286748856 },
{ "bake_from_source_geometry_data_async", 3669016597, 1286748856 },
{ "bake_from_source_geometry_data_async", 2469318639, 1286748856 },
}); });
mappings.insert("Node", { mappings.insert("Node", {
{ "add_child", 3070154285, 3863233950 }, { "add_child", 3070154285, 3863233950 },
@ -631,6 +675,11 @@ void GDExtensionCompatHashes::initialize() {
mappings.insert("ProjectSettings", { mappings.insert("ProjectSettings", {
{ "load_resource_pack", 3001721055, 708980503 }, { "load_resource_pack", 3001721055, 708980503 },
}); });
mappings.insert("RDShaderFile", {
{ "bake_from_source_geometry_data_async", 2469318639, 1286748856 },
{ "set_bytecode", 1558064255, 1526857008 },
{ "get_spirv", 3340165340, 2689310080 },
});
mappings.insert("RegEx", { mappings.insert("RegEx", {
{ "search", 4087180739, 3365977994 }, { "search", 4087180739, 3365977994 },
{ "search_all", 3354100289, 849021363 }, { "search_all", 3354100289, 849021363 },

View File

@ -1,40 +0,0 @@
/**************************************************************************/
/* object.compat.inc */
/**************************************************************************/
/* This file is part of: */
/* GODOT ENGINE */
/* https://godotengine.org */
/**************************************************************************/
/* Copyright (c) 2014-present Godot Engine contributors (see AUTHORS.md). */
/* Copyright (c) 2007-2014 Juan Linietsky, Ariel Manzur. */
/* */
/* Permission is hereby granted, free of charge, to any person obtaining */
/* a copy of this software and associated documentation files (the */
/* "Software"), to deal in the Software without restriction, including */
/* without limitation the rights to use, copy, modify, merge, publish, */
/* distribute, sublicense, and/or sell copies of the Software, and to */
/* permit persons to whom the Software is furnished to do so, subject to */
/* the following conditions: */
/* */
/* The above copyright notice and this permission notice shall be */
/* included in all copies or substantial portions of the Software. */
/* */
/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, */
/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF */
/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. */
/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY */
/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, */
/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE */
/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
/**************************************************************************/
#ifndef DISABLE_DEPRECATED
#include "core/object/class_db.h"
void Object::_bind_compatibility_methods() {
ClassDB::bind_compatibility_method(D_METHOD("tr", "message", "context"), &Object::tr, DEFVAL(""));
ClassDB::bind_compatibility_method(D_METHOD("tr_n", "message", "plural_message", "n", "context"), &Object::tr_n, DEFVAL(""));
}
#endif

View File

@ -29,7 +29,6 @@
/**************************************************************************/ /**************************************************************************/
#include "object.h" #include "object.h"
#include "object.compat.inc"
#include "core/extension/gdextension_manager.h" #include "core/extension/gdextension_manager.h"
#include "core/io/resource.h" #include "core/io/resource.h"

View File

@ -693,11 +693,7 @@ protected:
virtual void _notificationv(int p_notification, bool p_reversed) {} virtual void _notificationv(int p_notification, bool p_reversed) {}
static void _bind_methods(); static void _bind_methods();
#ifndef DISABLE_DEPRECATED
static void _bind_compatibility_methods();
#else
static void _bind_compatibility_methods() {} static void _bind_compatibility_methods() {}
#endif
bool _set(const StringName &p_name, const Variant &p_property) { return false; }; bool _set(const StringName &p_name, const Variant &p_property) { return false; };
bool _get(const StringName &p_name, Variant &r_property) const { return false; }; bool _get(const StringName &p_name, Variant &r_property) const { return false; };
void _get_property_list(List<PropertyInfo> *p_list) const {}; void _get_property_list(List<PropertyInfo> *p_list) const {};

View File

@ -162,6 +162,11 @@ void StringName::unref() {
_data = nullptr; _data = nullptr;
} }
uint32_t StringName::get_empty_hash() {
static uint32_t empty_hash = String::hash("");
return empty_hash;
}
bool StringName::operator==(const String &p_name) const { bool StringName::operator==(const String &p_name) const {
if (_data) { if (_data) {
return _data->operator==(p_name); return _data->operator==(p_name);

View File

@ -83,6 +83,7 @@ class StringName {
static inline Mutex mutex; static inline Mutex mutex;
static void setup(); static void setup();
static void cleanup(); static void cleanup();
static uint32_t get_empty_hash();
static inline bool configured = false; static inline bool configured = false;
#ifdef DEBUG_ENABLED #ifdef DEBUG_ENABLED
struct DebugSortReferences { struct DebugSortReferences {
@ -139,7 +140,7 @@ public:
if (_data) { if (_data) {
return _data->hash; return _data->hash;
} else { } else {
return 0; return get_empty_hash();
} }
} }
_FORCE_INLINE_ const void *data_unique_pointer() const { _FORCE_INLINE_ const void *data_unique_pointer() const {

View File

@ -1,41 +0,0 @@
/**************************************************************************/
/* translation.compat.inc */
/**************************************************************************/
/* This file is part of: */
/* GODOT ENGINE */
/* https://godotengine.org */
/**************************************************************************/
/* Copyright (c) 2014-present Godot Engine contributors (see AUTHORS.md). */
/* Copyright (c) 2007-2014 Juan Linietsky, Ariel Manzur. */
/* */
/* Permission is hereby granted, free of charge, to any person obtaining */
/* a copy of this software and associated documentation files (the */
/* "Software"), to deal in the Software without restriction, including */
/* without limitation the rights to use, copy, modify, merge, publish, */
/* distribute, sublicense, and/or sell copies of the Software, and to */
/* permit persons to whom the Software is furnished to do so, subject to */
/* the following conditions: */
/* */
/* The above copyright notice and this permission notice shall be */
/* included in all copies or substantial portions of the Software. */
/* */
/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, */
/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF */
/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. */
/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY */
/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, */
/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE */
/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
/**************************************************************************/
#ifndef DISABLE_DEPRECATED
void Translation::_bind_compatibility_methods() {
ClassDB::bind_compatibility_method(D_METHOD("add_message", "src_message", "xlated_message", "context"), &Translation::add_message, DEFVAL(""));
ClassDB::bind_compatibility_method(D_METHOD("add_plural_message", "src_message", "xlated_messages", "context"), &Translation::add_plural_message, DEFVAL(""));
ClassDB::bind_compatibility_method(D_METHOD("get_message", "src_message", "context"), &Translation::get_message, DEFVAL(""));
ClassDB::bind_compatibility_method(D_METHOD("get_plural_message", "src_message", "src_plural_message", "n", "context"), &Translation::get_plural_message, DEFVAL(""));
ClassDB::bind_compatibility_method(D_METHOD("erase_message", "src_message", "context"), &Translation::erase_message, DEFVAL(""));
}
#endif

View File

@ -29,7 +29,6 @@
/**************************************************************************/ /**************************************************************************/
#include "translation.h" #include "translation.h"
#include "translation.compat.inc"
#include "core/os/os.h" #include "core/os/os.h"
#include "core/os/thread.h" #include "core/os/thread.h"

View File

@ -51,10 +51,6 @@ class Translation : public Resource {
protected: protected:
static void _bind_methods(); static void _bind_methods();
#ifndef DISABLE_DEPRECATED
static void _bind_compatibility_methods();
#endif
GDVIRTUAL2RC(StringName, _get_message, StringName, StringName); GDVIRTUAL2RC(StringName, _get_message, StringName, StringName);
GDVIRTUAL4RC(StringName, _get_plural_message, StringName, StringName, int, StringName); GDVIRTUAL4RC(StringName, _get_plural_message, StringName, StringName, int, StringName);

View File

@ -1,38 +0,0 @@
/**************************************************************************/
/* translation_server.compat.inc */
/**************************************************************************/
/* This file is part of: */
/* GODOT ENGINE */
/* https://godotengine.org */
/**************************************************************************/
/* Copyright (c) 2014-present Godot Engine contributors (see AUTHORS.md). */
/* Copyright (c) 2007-2014 Juan Linietsky, Ariel Manzur. */
/* */
/* Permission is hereby granted, free of charge, to any person obtaining */
/* a copy of this software and associated documentation files (the */
/* "Software"), to deal in the Software without restriction, including */
/* without limitation the rights to use, copy, modify, merge, publish, */
/* distribute, sublicense, and/or sell copies of the Software, and to */
/* permit persons to whom the Software is furnished to do so, subject to */
/* the following conditions: */
/* */
/* The above copyright notice and this permission notice shall be */
/* included in all copies or substantial portions of the Software. */
/* */
/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, */
/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF */
/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. */
/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY */
/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, */
/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE */
/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
/**************************************************************************/
#ifndef DISABLE_DEPRECATED
void TranslationServer::_bind_compatibility_methods() {
ClassDB::bind_compatibility_method(D_METHOD("translate", "message", "context"), &TranslationServer::translate, DEFVAL(""));
ClassDB::bind_compatibility_method(D_METHOD("translate_plural", "message", "plural_message", "n", "context"), &TranslationServer::translate_plural, DEFVAL(""));
}
#endif

View File

@ -29,7 +29,6 @@
/**************************************************************************/ /**************************************************************************/
#include "translation_server.h" #include "translation_server.h"
#include "translation_server.compat.inc"
#include "core/config/project_settings.h" #include "core/config/project_settings.h"
#include "core/io/resource_loader.h" #include "core/io/resource_loader.h"

View File

@ -74,10 +74,6 @@ class TranslationServer : public Object {
static void _bind_methods(); static void _bind_methods();
#ifndef DISABLE_DEPRECATED
static void _bind_compatibility_methods();
#endif
struct LocaleScriptInfo { struct LocaleScriptInfo {
String name; String name;
String script; String script;

View File

@ -58,14 +58,6 @@ void AnimationPlayer::_seek_bind_compat_80813(double p_time, bool p_update) {
seek(p_time, p_update, false); seek(p_time, p_update, false);
} }
void AnimationPlayer::_play_compat_84906(const StringName &p_name, double p_custom_blend, float p_custom_scale, bool p_from_end) {
play(p_name, p_custom_blend, p_custom_scale, p_from_end);
}
void AnimationPlayer::_play_backwards_compat_84906(const StringName &p_name, double p_custom_blend) {
play_backwards(p_name, p_custom_blend);
}
void AnimationPlayer::_bind_compatibility_methods() { void AnimationPlayer::_bind_compatibility_methods() {
ClassDB::bind_method(D_METHOD("set_process_callback", "mode"), &AnimationPlayer::_set_process_callback_bind_compat_80813); ClassDB::bind_method(D_METHOD("set_process_callback", "mode"), &AnimationPlayer::_set_process_callback_bind_compat_80813);
ClassDB::bind_method(D_METHOD("get_process_callback"), &AnimationPlayer::_get_process_callback_bind_compat_80813); ClassDB::bind_method(D_METHOD("get_process_callback"), &AnimationPlayer::_get_process_callback_bind_compat_80813);
@ -74,8 +66,6 @@ void AnimationPlayer::_bind_compatibility_methods() {
ClassDB::bind_method(D_METHOD("set_root", "path"), &AnimationPlayer::_set_root_bind_compat_80813); ClassDB::bind_method(D_METHOD("set_root", "path"), &AnimationPlayer::_set_root_bind_compat_80813);
ClassDB::bind_method(D_METHOD("get_root"), &AnimationPlayer::_get_root_bind_compat_80813); ClassDB::bind_method(D_METHOD("get_root"), &AnimationPlayer::_get_root_bind_compat_80813);
ClassDB::bind_compatibility_method(D_METHOD("seek", "seconds", "update"), &AnimationPlayer::_seek_bind_compat_80813, DEFVAL(false)); ClassDB::bind_compatibility_method(D_METHOD("seek", "seconds", "update"), &AnimationPlayer::_seek_bind_compat_80813, DEFVAL(false));
ClassDB::bind_compatibility_method(D_METHOD("play", "name", "custom_blend", "custom_speed", "from_end"), &AnimationPlayer::_play_compat_84906, DEFVAL(""), DEFVAL(-1), DEFVAL(1.0), DEFVAL(false));
ClassDB::bind_compatibility_method(D_METHOD("play_backwards", "name", "custom_blend"), &AnimationPlayer::_play_backwards_compat_84906, DEFVAL(""), DEFVAL(-1));
BIND_ENUM_CONSTANT(ANIMATION_PROCESS_PHYSICS); BIND_ENUM_CONSTANT(ANIMATION_PROCESS_PHYSICS);
BIND_ENUM_CONSTANT(ANIMATION_PROCESS_IDLE); BIND_ENUM_CONSTANT(ANIMATION_PROCESS_IDLE);
BIND_ENUM_CONSTANT(ANIMATION_PROCESS_MANUAL); BIND_ENUM_CONSTANT(ANIMATION_PROCESS_MANUAL);

View File

@ -1,48 +0,0 @@
/**************************************************************************/
/* control.compat.inc */
/**************************************************************************/
/* This file is part of: */
/* GODOT ENGINE */
/* https://godotengine.org */
/**************************************************************************/
/* Copyright (c) 2014-present Godot Engine contributors (see AUTHORS.md). */
/* Copyright (c) 2007-2014 Juan Linietsky, Ariel Manzur. */
/* */
/* Permission is hereby granted, free of charge, to any person obtaining */
/* a copy of this software and associated documentation files (the */
/* "Software"), to deal in the Software without restriction, including */
/* without limitation the rights to use, copy, modify, merge, publish, */
/* distribute, sublicense, and/or sell copies of the Software, and to */
/* permit persons to whom the Software is furnished to do so, subject to */
/* the following conditions: */
/* */
/* The above copyright notice and this permission notice shall be */
/* included in all copies or substantial portions of the Software. */
/* */
/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, */
/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF */
/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. */
/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY */
/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, */
/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE */
/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
/**************************************************************************/
#ifndef DISABLE_DEPRECATED
void Control::_bind_compatibility_methods() {
ClassDB::bind_compatibility_method(D_METHOD("get_theme_icon", "name", "theme_type"), &Control::get_theme_icon, DEFVAL(""));
ClassDB::bind_compatibility_method(D_METHOD("get_theme_stylebox", "name", "theme_type"), &Control::get_theme_stylebox, DEFVAL(""));
ClassDB::bind_compatibility_method(D_METHOD("get_theme_font", "name", "theme_type"), &Control::get_theme_font, DEFVAL(""));
ClassDB::bind_compatibility_method(D_METHOD("get_theme_font_size", "name", "theme_type"), &Control::get_theme_font_size, DEFVAL(""));
ClassDB::bind_compatibility_method(D_METHOD("get_theme_color", "name", "theme_type"), &Control::get_theme_color, DEFVAL(""));
ClassDB::bind_compatibility_method(D_METHOD("get_theme_constant", "name", "theme_type"), &Control::get_theme_constant, DEFVAL(""));
ClassDB::bind_compatibility_method(D_METHOD("has_theme_icon", "name", "theme_type"), &Control::has_theme_icon, DEFVAL(""));
ClassDB::bind_compatibility_method(D_METHOD("has_theme_stylebox", "name", "theme_type"), &Control::has_theme_stylebox, DEFVAL(""));
ClassDB::bind_compatibility_method(D_METHOD("has_theme_font", "name", "theme_type"), &Control::has_theme_font, DEFVAL(""));
ClassDB::bind_compatibility_method(D_METHOD("has_theme_font_size", "name", "theme_type"), &Control::has_theme_font_size, DEFVAL(""));
ClassDB::bind_compatibility_method(D_METHOD("has_theme_color", "name", "theme_type"), &Control::has_theme_color, DEFVAL(""));
ClassDB::bind_compatibility_method(D_METHOD("has_theme_constant", "name", "theme_type"), &Control::has_theme_constant, DEFVAL(""));
}
#endif

View File

@ -29,7 +29,6 @@
/**************************************************************************/ /**************************************************************************/
#include "control.h" #include "control.h"
#include "control.compat.inc"
#include "container.h" #include "container.h"
#include "core/config/project_settings.h" #include "core/config/project_settings.h"

View File

@ -348,10 +348,6 @@ protected:
void _notification(int p_notification); void _notification(int p_notification);
static void _bind_methods(); static void _bind_methods();
#ifndef DISABLE_DEPRECATED
static void _bind_compatibility_methods();
#endif
// Exposed virtual methods. // Exposed virtual methods.
GDVIRTUAL1RC(bool, _has_point, Vector2) GDVIRTUAL1RC(bool, _has_point, Vector2)

View File

@ -1,48 +0,0 @@
/**************************************************************************/
/* window.compat.inc */
/**************************************************************************/
/* This file is part of: */
/* GODOT ENGINE */
/* https://godotengine.org */
/**************************************************************************/
/* Copyright (c) 2014-present Godot Engine contributors (see AUTHORS.md). */
/* Copyright (c) 2007-2014 Juan Linietsky, Ariel Manzur. */
/* */
/* Permission is hereby granted, free of charge, to any person obtaining */
/* a copy of this software and associated documentation files (the */
/* "Software"), to deal in the Software without restriction, including */
/* without limitation the rights to use, copy, modify, merge, publish, */
/* distribute, sublicense, and/or sell copies of the Software, and to */
/* permit persons to whom the Software is furnished to do so, subject to */
/* the following conditions: */
/* */
/* The above copyright notice and this permission notice shall be */
/* included in all copies or substantial portions of the Software. */
/* */
/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, */
/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF */
/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. */
/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY */
/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, */
/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE */
/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
/**************************************************************************/
#ifndef DISABLE_DEPRECATED
void Window::_bind_compatibility_methods() {
ClassDB::bind_compatibility_method(D_METHOD("get_theme_icon", "name", "theme_type"), &Window::get_theme_icon, DEFVAL(""));
ClassDB::bind_compatibility_method(D_METHOD("get_theme_stylebox", "name", "theme_type"), &Window::get_theme_stylebox, DEFVAL(""));
ClassDB::bind_compatibility_method(D_METHOD("get_theme_font", "name", "theme_type"), &Window::get_theme_font, DEFVAL(""));
ClassDB::bind_compatibility_method(D_METHOD("get_theme_font_size", "name", "theme_type"), &Window::get_theme_font_size, DEFVAL(""));
ClassDB::bind_compatibility_method(D_METHOD("get_theme_color", "name", "theme_type"), &Window::get_theme_color, DEFVAL(""));
ClassDB::bind_compatibility_method(D_METHOD("get_theme_constant", "name", "theme_type"), &Window::get_theme_constant, DEFVAL(""));
ClassDB::bind_compatibility_method(D_METHOD("has_theme_icon", "name", "theme_type"), &Window::has_theme_icon, DEFVAL(""));
ClassDB::bind_compatibility_method(D_METHOD("has_theme_stylebox", "name", "theme_type"), &Window::has_theme_stylebox, DEFVAL(""));
ClassDB::bind_compatibility_method(D_METHOD("has_theme_font", "name", "theme_type"), &Window::has_theme_font, DEFVAL(""));
ClassDB::bind_compatibility_method(D_METHOD("has_theme_font_size", "name", "theme_type"), &Window::has_theme_font_size, DEFVAL(""));
ClassDB::bind_compatibility_method(D_METHOD("has_theme_color", "name", "theme_type"), &Window::has_theme_color, DEFVAL(""));
ClassDB::bind_compatibility_method(D_METHOD("has_theme_constant", "name", "theme_type"), &Window::has_theme_constant, DEFVAL(""));
}
#endif

View File

@ -29,7 +29,6 @@
/**************************************************************************/ /**************************************************************************/
#include "window.h" #include "window.h"
#include "window.compat.inc"
#include "core/config/project_settings.h" #include "core/config/project_settings.h"
#include "core/debugger/engine_debugger.h" #include "core/debugger/engine_debugger.h"

View File

@ -247,10 +247,6 @@ protected:
void _notification(int p_what); void _notification(int p_what);
static void _bind_methods(); static void _bind_methods();
#ifndef DISABLE_DEPRECATED
static void _bind_compatibility_methods();
#endif
bool _set(const StringName &p_name, const Variant &p_value); bool _set(const StringName &p_name, const Variant &p_value);
bool _get(const StringName &p_name, Variant &r_ret) const; bool _get(const StringName &p_name, Variant &r_ret) const;
void _get_property_list(List<PropertyInfo> *p_list) const; void _get_property_list(List<PropertyInfo> *p_list) const;