Merge pull request #189 from ydeltastar/filter-fix

Make player filter in the debugger case-insensitive
This commit is contained in:
Serhii Snitsaruk 2024-08-07 10:11:19 +02:00 committed by GitHub
commit f14a19b947
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 2 additions and 1 deletions

View File

@ -120,8 +120,9 @@ void LimboDebuggerTab::_update_bt_instance_list(const Vector<BTInstanceInfo> &p_
bt_instance_list->clear();
int select_idx = -1;
bool selection_filtered_out = false;
String filter = p_filter.to_lower();
for (const BTInstanceInfo &info : p_instances) {
if (p_filter.is_empty() || info.owner_node_path.contains(p_filter)) {
if (filter.is_empty() || info.owner_node_path.to_lower().contains(filter)) {
int idx = bt_instance_list->add_item(info.owner_node_path);
bt_instance_list->set_item_metadata(idx, info.instance_id);
// Make item text shortened from the left, e.g ".../Agent/BTPlayer".