forked from bartvdbraak/blender
Additonal fix for r35724
(bugfix #26573, #26574 and #26551) Layer visibility code for hotkeys uses different code still, added same new DAG_on_visible_update() in this operator.
This commit is contained in:
parent
2c4999eccb
commit
9019d3b1f2
@ -152,8 +152,6 @@ static int view3d_layers_exec(bContext *C, wmOperator *op)
|
|||||||
Scene *scene= CTX_data_scene(C);
|
Scene *scene= CTX_data_scene(C);
|
||||||
ScrArea *sa= CTX_wm_area(C);
|
ScrArea *sa= CTX_wm_area(C);
|
||||||
View3D *v3d= sa->spacedata.first;
|
View3D *v3d= sa->spacedata.first;
|
||||||
Base *base;
|
|
||||||
int oldlay= v3d->lay;
|
|
||||||
int nr= RNA_int_get(op->ptr, "nr");
|
int nr= RNA_int_get(op->ptr, "nr");
|
||||||
int toggle= RNA_boolean_get(op->ptr, "toggle");
|
int toggle= RNA_boolean_get(op->ptr, "toggle");
|
||||||
|
|
||||||
@ -211,12 +209,7 @@ static int view3d_layers_exec(bContext *C, wmOperator *op)
|
|||||||
|
|
||||||
if(v3d->scenelock) handle_view3d_lock(C);
|
if(v3d->scenelock) handle_view3d_lock(C);
|
||||||
|
|
||||||
/* XXX new layers might need updates, there is no provision yet to detect if that's needed */
|
DAG_on_visible_update(CTX_data_main(C), FALSE);
|
||||||
oldlay= ~oldlay & v3d->lay;
|
|
||||||
for (base= scene->base.first; base; base= base->next) {
|
|
||||||
if(base->lay & oldlay)
|
|
||||||
base->object->recalc= OB_RECALC_OB|OB_RECALC_DATA;
|
|
||||||
}
|
|
||||||
|
|
||||||
ED_area_tag_redraw(sa);
|
ED_area_tag_redraw(sa);
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user