Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSergey Sharybin <sergey.vfx@gmail.com>2018-12-06 19:52:37 +0300
committerSergey Sharybin <sergey.vfx@gmail.com>2018-12-07 13:37:38 +0300
commit79312c1912b4fdb830e38a856cf88bfca8e4703d (patch)
tree74d5b262de9cd5d044e1963df13f2cbe73c3b796 /source/blender/editors/space_outliner/outliner_select.c
parent989fbff16f49204ca31a67f56f87c2221e0246f4 (diff)
Depsgraph: Remove duplicated sets of recalc/update flags
There were at least three copies of those: - OB_RECALC* family of flags, which are rudiment of an old dependency graph system. - PSYS_RECALC* which were used by old dependency graph system as a separate set since the graph itself did not handle particle systems. - DEG_TAG_* which was used to tag IDs. Now there is a single set, which defines what can be tagged and queried for an update. It also has some aggregate flags to make queries simpler. Lets once and for all solve the madness of those flags, stick to a single set, which will not overlap with anything or require any extra conversion. Technically, shouldn't be measurable user difference, but some of the agregate flags for few dependency graph components did change. Fixes T58632: Particle don't update rotation settings
Diffstat (limited to 'source/blender/editors/space_outliner/outliner_select.c')
-rw-r--r--source/blender/editors/space_outliner/outliner_select.c18
1 files changed, 9 insertions, 9 deletions
diff --git a/source/blender/editors/space_outliner/outliner_select.c b/source/blender/editors/space_outliner/outliner_select.c
index efe27b5be89..d9e069f75c2 100644
--- a/source/blender/editors/space_outliner/outliner_select.c
+++ b/source/blender/editors/space_outliner/outliner_select.c
@@ -85,7 +85,7 @@ static void do_outliner_activate_obdata(bContext *C, Scene *scene, ViewLayer *vi
if (obact == NULL) {
ED_object_base_activate(C, base);
- DEG_id_tag_update(&scene->id, DEG_TAG_SELECT_UPDATE);
+ DEG_id_tag_update(&scene->id, ID_RECALC_SELECT);
WM_event_add_notifier(C, NC_SCENE | ND_OB_SELECT, scene);
obact = base->object;
use_all = true;
@@ -109,7 +109,7 @@ static void do_outliner_activate_obdata(bContext *C, Scene *scene, ViewLayer *vi
}
if (ok) {
ED_object_base_select(base, (ob->mode & OB_MODE_EDIT) ? BA_SELECT : BA_DESELECT);
- DEG_id_tag_update(&scene->id, DEG_TAG_SELECT_UPDATE);
+ DEG_id_tag_update(&scene->id, ID_RECALC_SELECT);
WM_event_add_notifier(C, NC_SCENE | ND_OB_SELECT, scene);
}
}
@@ -124,7 +124,7 @@ static void do_outliner_activate_pose(bContext *C, ViewLayer *view_layer, Base *
if (obact == NULL) {
ED_object_base_activate(C, base);
Scene *scene = CTX_data_scene(C);
- DEG_id_tag_update(&scene->id, DEG_TAG_SELECT_UPDATE);
+ DEG_id_tag_update(&scene->id, ID_RECALC_SELECT);
WM_event_add_notifier(C, NC_SCENE | ND_OB_SELECT, scene);
obact = base->object;
use_all = true;
@@ -151,7 +151,7 @@ static void do_outliner_activate_pose(bContext *C, ViewLayer *view_layer, Base *
ED_object_base_select(base, (ob->mode & OB_MODE_POSE) ? BA_SELECT : BA_DESELECT);
Scene *scene = CTX_data_scene(C);
- DEG_id_tag_update(&scene->id, DEG_TAG_SELECT_UPDATE);
+ DEG_id_tag_update(&scene->id, ID_RECALC_SELECT);
WM_event_add_notifier(C, NC_SCENE | ND_MODE | NS_MODE_OBJECT, NULL);
WM_event_add_notifier(C, NC_SCENE | ND_OB_SELECT, scene);
}
@@ -318,7 +318,7 @@ static eOLDrawState tree_element_set_active_object(
if (set != OL_SETSEL_NONE) {
ED_object_base_activate(C, base); /* adds notifier */
- DEG_id_tag_update(&scene->id, DEG_TAG_SELECT_UPDATE);
+ DEG_id_tag_update(&scene->id, ID_RECALC_SELECT);
WM_event_add_notifier(C, NC_SCENE | ND_OB_SELECT, scene);
}
@@ -376,7 +376,7 @@ static eOLDrawState tree_element_active_material(
/* Tagging object for update seems a bit stupid here, but looks like we have to do it
* for render views to update. See T42973.
* Note that RNA material update does it too, see e.g. rna_MaterialSlot_update(). */
- DEG_id_tag_update((ID *)ob, OB_RECALC_OB);
+ DEG_id_tag_update((ID *)ob, ID_RECALC_TRANSFORM);
WM_event_add_notifier(C, NC_MATERIAL | ND_SHADING_LINKS, NULL);
}
return OL_DRAWSEL_NONE;
@@ -462,7 +462,7 @@ static eOLDrawState tree_element_active_defgroup(
BLI_assert(te->index + 1 >= 0);
ob->actdef = te->index + 1;
- DEG_id_tag_update(&ob->id, OB_RECALC_DATA);
+ DEG_id_tag_update(&ob->id, ID_RECALC_GEOMETRY);
WM_event_add_notifier(C, NC_OBJECT | ND_TRANSFORM, ob);
}
else {
@@ -1020,7 +1020,7 @@ static void do_outliner_item_activate_tree_element(
FOREACH_COLLECTION_OBJECT_RECURSIVE_END;
}
- DEG_id_tag_update(&scene->id, DEG_TAG_SELECT_UPDATE);
+ DEG_id_tag_update(&scene->id, ID_RECALC_SELECT);
WM_event_add_notifier(C, NC_SCENE | ND_OB_SELECT, scene);
}
else if (OB_DATA_SUPPORT_EDITMODE(te->idcode)) {
@@ -1225,7 +1225,7 @@ static int outliner_box_select_exec(bContext *C, wmOperator *op)
outliner_item_box_select(scene, &rectf, te, select);
}
- DEG_id_tag_update(&scene->id, DEG_TAG_SELECT_UPDATE);
+ DEG_id_tag_update(&scene->id, ID_RECALC_SELECT);
WM_event_add_notifier(C, NC_SCENE | ND_OB_SELECT, scene);
ED_region_tag_redraw(ar);