diff options
| author | Rémi Verschelde <remi@verschelde.fr> | 2021-03-17 13:00:03 +0100 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2021-03-17 13:00:03 +0100 |
| commit | 3ef0e5a9bca4399c25b0cd3e174bbbcdb7df8d5e (patch) | |
| tree | 7c4cee1e79f35eea5d35fe921d9eeb709bbf58aa /modules/gdnative/nativescript | |
| parent | af0806722f465d505976bfb07eccd724759fba48 (diff) | |
| parent | ec806c5c5bc0abc2e1d01a96f7f7ea1b6da189fb (diff) | |
| download | redot-engine-3ef0e5a9bca4399c25b0cd3e174bbbcdb7df8d5e.tar.gz | |
Merge pull request #46431 from vnen/gdnative-bindings
Further changes in GDNative API
Diffstat (limited to 'modules/gdnative/nativescript')
| -rw-r--r-- | modules/gdnative/nativescript/api_generator.cpp | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/modules/gdnative/nativescript/api_generator.cpp b/modules/gdnative/nativescript/api_generator.cpp index 3e75478cd8..f184c84615 100644 --- a/modules/gdnative/nativescript/api_generator.cpp +++ b/modules/gdnative/nativescript/api_generator.cpp @@ -71,6 +71,7 @@ struct MethodAPI { bool is_editor = false; bool is_noscript = false; bool is_const = false; + bool is_static = false; // For builtin types. bool is_reverse = false; bool is_virtual = false; bool is_from_script = false; @@ -528,6 +529,7 @@ List<ClassAPI> generate_c_builtin_api_types() { method_api.argument_count = Variant::get_builtin_method_argument_count(type, method_name); method_api.has_varargs = Variant::is_builtin_method_vararg(type, method_name); method_api.is_const = Variant::is_builtin_method_const(type, method_name); + method_api.is_static = Variant::is_builtin_method_static(type, method_name); for (int i = 0; i < method_api.argument_count; i++) { method_api.argument_names.push_back(Variant::get_builtin_method_argument_name(type, method_name, i)); @@ -757,6 +759,7 @@ static void write_builtin_method(StringBuilder &p_source, const MethodAPI &p_met append_indented(p_source, vformat(R"("name": "%s",)", p_method.method_name)); append_indented(p_source, vformat(R"("return_type": "%s",)", p_method.return_type)); append_indented(p_source, vformat(R"("is_const": %s,)", p_method.is_const ? "true" : "false")); + append_indented(p_source, vformat(R"("is_static": %s,)", p_method.is_static ? "true" : "false")); append_indented(p_source, vformat(R"("has_varargs": %s,)", p_method.has_varargs ? "true" : "false")); append_indented(p_source, R"("arguments": [)"); |
