Fix T59322: View Layer - Search not working
Basically uiRNACollectionSearch->but_changed was always NULL for the search templates. So skip_filter would always be true, and we would never filter. An alternative fix would be to add the following to the begin of `template_search_add_button_searchmenu`: ``` static bool always_true = true; template_search->search_data.but_changed = &always_true; ```
This commit is contained in:
@@ -255,7 +255,7 @@ void ui_rna_collection_search_cb(const struct bContext *C, void *arg, const char
|
|||||||
int i = 0, iconid = 0, flag = RNA_property_flag(data->target_prop);
|
int i = 0, iconid = 0, flag = RNA_property_flag(data->target_prop);
|
||||||
ListBase *items_list = MEM_callocN(sizeof(ListBase), "items_list");
|
ListBase *items_list = MEM_callocN(sizeof(ListBase), "items_list");
|
||||||
CollItemSearch *cis;
|
CollItemSearch *cis;
|
||||||
const bool skip_filter = !(data->but_changed && *data->but_changed);
|
const bool skip_filter = (data->but_changed && !(*data->but_changed));
|
||||||
|
|
||||||
/* build a temporary list of relevant items first */
|
/* build a temporary list of relevant items first */
|
||||||
RNA_PROP_BEGIN (&data->search_ptr, itemptr, data->search_prop)
|
RNA_PROP_BEGIN (&data->search_ptr, itemptr, data->search_prop)
|
||||||
|
|||||||
Reference in New Issue
Block a user