diff options
author | Rémi Verschelde <remi@verschelde.fr> | 2022-07-06 09:35:40 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-07-06 09:35:40 +0200 |
commit | cf194847468e00de682074a14b2cf4ccf7b69188 (patch) | |
tree | 4ebf367bf5fe4db50db3342707cfae7c2c5e91d6 /core/extension/extension_api_dump.cpp | |
parent | 398ab31a6bcf1a80a6fc13a56e2f7f8558303d51 (diff) | |
parent | 5ac42cf5766cd60a9c41bdd6045c8ccfd35d62c1 (diff) | |
download | redot-engine-cf194847468e00de682074a14b2cf4ccf7b69188.tar.gz |
Merge pull request #62374 from reduz/implement-bitfield-hint
Implement a BitField hint
Diffstat (limited to 'core/extension/extension_api_dump.cpp')
-rw-r--r-- | core/extension/extension_api_dump.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/core/extension/extension_api_dump.cpp b/core/extension/extension_api_dump.cpp index 9d846f87c2..d5c49b01e9 100644 --- a/core/extension/extension_api_dump.cpp +++ b/core/extension/extension_api_dump.cpp @@ -46,7 +46,7 @@ static String get_type_name(const PropertyInfo &p_info) { return p_info.hint_string + "*"; } } - if (p_info.type == Variant::INT && (p_info.usage & PROPERTY_USAGE_CLASS_IS_ENUM)) { + if (p_info.type == Variant::INT && (p_info.usage & (PROPERTY_USAGE_CLASS_IS_ENUM | PROPERTY_USAGE_CLASS_IS_BITFIELD))) { return String("enum::") + String(p_info.class_name); } if (p_info.class_name != StringName()) { @@ -665,6 +665,7 @@ Dictionary NativeExtensionAPIDump::generate_extension_api() { for (const StringName &F : enum_list) { Dictionary d2; d2["name"] = String(F); + d2["is_bitfield"] = ClassDB::is_enum_bitfield(class_name, F); Array values; List<StringName> enum_constant_list; |