You've already forked godot
mirror of
https://github.com/godotengine/godot.git
synced 2025-11-13 13:31:48 +00:00
Synchronize parameter names in definition and declaration
Fixes #10244.
This commit is contained in:
committed by
Rémi Verschelde
parent
b1ecaaa22b
commit
00f6c85928
@@ -185,21 +185,21 @@ void OptionButton::clear() {
|
||||
current = -1;
|
||||
}
|
||||
|
||||
void OptionButton::_select(int p_idx, bool p_emit) {
|
||||
void OptionButton::_select(int p_which, bool p_emit) {
|
||||
|
||||
if (p_idx < 0)
|
||||
if (p_which < 0)
|
||||
return;
|
||||
if (p_idx == current)
|
||||
if (p_which == current)
|
||||
return;
|
||||
|
||||
ERR_FAIL_INDEX(p_idx, popup->get_item_count());
|
||||
ERR_FAIL_INDEX(p_which, popup->get_item_count());
|
||||
|
||||
for (int i = 0; i < popup->get_item_count(); i++) {
|
||||
|
||||
popup->set_item_checked(i, i == p_idx);
|
||||
popup->set_item_checked(i, i == p_which);
|
||||
}
|
||||
|
||||
current = p_idx;
|
||||
current = p_which;
|
||||
set_text(popup->get_item_text(current));
|
||||
set_icon(popup->get_item_icon(current));
|
||||
|
||||
|
||||
Reference in New Issue
Block a user