Fix T62025: Outliner and viewport missing update after deleting object

Bug introduced on 012483b6e4.

Since we notify similar things when changing active and selected
objects, I believe we didn't notice this was missing a ND_OB_SELECT
notification before the small refactor to use the messenging system
exposed that bug.
This commit is contained in:
Dalai Felinto
2019-03-01 16:18:05 -03:00
parent 943e4ec8f1
commit 589d089472

View File

@@ -1057,6 +1057,7 @@ static int outliner_object_operation_exec(bContext *C, wmOperator *op)
DEG_relations_tag_update(bmain);
str = "Delete Objects";
DEG_id_tag_update(&scene->id, ID_RECALC_SELECT);
WM_event_add_notifier(C, NC_SCENE | ND_OB_SELECT, scene);
if (basact_prev != BASACT(view_layer)) {
WM_event_add_notifier(C, NC_SCENE | ND_OB_ACTIVE, scene);
WM_msg_publish_rna_prop(mbus, &scene->id, view_layer, LayerObjects, active);
@@ -1086,7 +1087,7 @@ static int outliner_object_operation_exec(bContext *C, wmOperator *op)
DEG_relations_tag_update(bmain);
str = "Delete Object Hierarchy";
DEG_id_tag_update(&scene->id, ID_RECALC_SELECT);
WM_event_add_notifier(C, NC_SCENE | ND_OB_ACTIVE, scene);
WM_event_add_notifier(C, NC_SCENE | ND_OB_SELECT, scene);
if (basact_prev != BASACT(view_layer)) {
WM_event_add_notifier(C, NC_SCENE | ND_OB_ACTIVE, scene);
WM_msg_publish_rna_prop(mbus, &scene->id, view_layer, LayerObjects, active);