mirror of
https://github.com/blender/blender
synced 2026-09-29 04:37:17 +03:00
Fix: View: Don't delete items that are filtered out
Pressing X over tree view will delete active item regardless it's filtered out by search string. Add `is_filtered_visible` to avoid this. Pull Request: https://projects.blender.org/blender/blender/pulls/155762
This commit is contained in:
parent
c0eb6dd64e
commit
bcdf4fbde3
1 changed files with 3 additions and 0 deletions
|
|
@ -2906,6 +2906,9 @@ static wmOperatorStatus view_item_delete_invoke(bContext *C,
|
|||
AbstractView *view = get_view_focused(C);
|
||||
|
||||
view->foreach_view_item([&](AbstractViewItem &item) {
|
||||
if (!item.is_filtered_visible()) {
|
||||
return;
|
||||
}
|
||||
if (item.is_active() || item.is_selected()) {
|
||||
item.delete_item(C);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue