diff options
author | Rémi Verschelde <rverschelde@gmail.com> | 2022-01-07 13:58:28 +0100 |
---|---|---|
committer | Rémi Verschelde <rverschelde@gmail.com> | 2022-01-07 14:24:06 +0100 |
commit | fcc2648e18f0b6bcfd2b4e70829078346dc74b36 (patch) | |
tree | 51589af6766405604a1fd2abe6cfe465fa918b2b | |
parent | 50225a0f32bbf37469affb0a0797fae76ff8fdac (diff) |
Fix missing arg name in bindings for GDExtension API
-rw-r--r-- | core/core_bind.cpp | 4 | ||||
-rw-r--r-- | scene/gui/option_button.cpp | 3 | ||||
-rw-r--r-- | scene/gui/tab_bar.cpp | 2 |
3 files changed, 5 insertions, 4 deletions
diff --git a/core/core_bind.cpp b/core/core_bind.cpp index fd99aa7f00..1891ea7e3a 100644 --- a/core/core_bind.cpp +++ b/core/core_bind.cpp @@ -1672,9 +1672,9 @@ void Directory::_bind_methods() { ClassDB::bind_method(D_METHOD("rename", "from", "to"), &Directory::rename); ClassDB::bind_method(D_METHOD("remove", "path"), &Directory::remove); - ClassDB::bind_method(D_METHOD("set_include_navigational"), &Directory::set_include_navigational); + ClassDB::bind_method(D_METHOD("set_include_navigational", "enable"), &Directory::set_include_navigational); ClassDB::bind_method(D_METHOD("get_include_navigational"), &Directory::get_include_navigational); - ClassDB::bind_method(D_METHOD("set_include_hidden"), &Directory::set_include_hidden); + ClassDB::bind_method(D_METHOD("set_include_hidden", "enable"), &Directory::set_include_hidden); ClassDB::bind_method(D_METHOD("get_include_hidden"), &Directory::get_include_hidden); ADD_PROPERTY(PropertyInfo(Variant::BOOL, "include_navigational"), "set_include_navigational", "get_include_navigational"); diff --git a/scene/gui/option_button.cpp b/scene/gui/option_button.cpp index e721b01cbc..e955fde43a 100644 --- a/scene/gui/option_button.cpp +++ b/scene/gui/option_button.cpp @@ -359,8 +359,9 @@ void OptionButton::_bind_methods() { ClassDB::bind_method(D_METHOD("get_popup"), &OptionButton::get_popup); - ClassDB::bind_method(D_METHOD("set_item_count"), &OptionButton::set_item_count); + ClassDB::bind_method(D_METHOD("set_item_count", "count"), &OptionButton::set_item_count); ClassDB::bind_method(D_METHOD("get_item_count"), &OptionButton::get_item_count); + // "selected" property must come after "item_count", otherwise GH-10213 occurs. ADD_ARRAY_COUNT("Items", "item_count", "set_item_count", "get_item_count", "popup/item_"); ADD_PROPERTY(PropertyInfo(Variant::INT, "selected"), "_select_int", "get_selected"); diff --git a/scene/gui/tab_bar.cpp b/scene/gui/tab_bar.cpp index f7ae101690..92da169487 100644 --- a/scene/gui/tab_bar.cpp +++ b/scene/gui/tab_bar.cpp @@ -1188,7 +1188,7 @@ void TabBar::_get_property_list(List<PropertyInfo> *p_list) const { void TabBar::_bind_methods() { ClassDB::bind_method(D_METHOD("_update_hover"), &TabBar::_update_hover); - ClassDB::bind_method(D_METHOD("set_tab_count"), &TabBar::set_tab_count); + ClassDB::bind_method(D_METHOD("set_tab_count", "count"), &TabBar::set_tab_count); ClassDB::bind_method(D_METHOD("get_tab_count"), &TabBar::get_tab_count); ClassDB::bind_method(D_METHOD("set_current_tab", "tab_idx"), &TabBar::set_current_tab); ClassDB::bind_method(D_METHOD("get_current_tab"), &TabBar::get_current_tab); |