Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add _bind_compatibility_methods to Object #79702

Merged
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 10 additions & 0 deletions core/object/object.h
Original file line number Diff line number Diff line change
Expand Up @@ -429,6 +429,9 @@ public:
protected: \
_FORCE_INLINE_ static void (*_get_bind_methods())() { \
return &m_class::_bind_methods; \
} \
_FORCE_INLINE_ static void (*_get_bind_compatibility_methods())() { \
return &m_class::_bind_compatibility_methods; \
} \
\
public: \
Expand All @@ -442,6 +445,9 @@ public:
if (m_class::_get_bind_methods() != m_inherits::_get_bind_methods()) { \
_bind_methods(); \
} \
if (m_class::_get_bind_compatibility_methods() != m_inherits::_get_bind_compatibility_methods()) { \
_bind_compatibility_methods(); \
} \
initialized = true; \
} \
\
Expand Down Expand Up @@ -674,6 +680,7 @@ class Object {
virtual void _notificationv(int p_notification, bool p_reversed) {}

static void _bind_methods();
static void _bind_compatibility_methods() {}
bool _set(const StringName &p_name, const Variant &p_property) { return false; };
bool _get(const StringName &p_name, Variant &r_property) const { return false; };
void _get_property_list(List<PropertyInfo> *p_list) const {};
Expand All @@ -685,6 +692,9 @@ class Object {
_FORCE_INLINE_ static void (*_get_bind_methods())() {
return &Object::_bind_methods;
}
_FORCE_INLINE_ static void (*_get_bind_compatibility_methods())() {
return &Object::_bind_compatibility_methods;
}
_FORCE_INLINE_ bool (Object::*_get_get() const)(const StringName &p_name, Variant &r_ret) const {
return &Object::_get;
}
Expand Down
Loading