Dopesheet: fix crash when dragging keyframes
This commit is contained in:
@@ -380,9 +380,9 @@ bool ANIM_animdata_get_context(const bContext *C, bAnimContext *ac)
|
||||
ac->scene = scene;
|
||||
if (scene) {
|
||||
ac->markers = ED_context_get_markers(C);
|
||||
ac->obact = (scene->basact) ? scene->basact->object : NULL;
|
||||
}
|
||||
ac->scene_layer = CTX_data_scene_layer(C);
|
||||
ac->obact = (ac->scene_layer->basact) ? ac->scene_layer->basact->object : NULL;
|
||||
ac->sa = sa;
|
||||
ac->ar = ar;
|
||||
ac->sl = sl;
|
||||
|
||||
@@ -325,6 +325,7 @@ static void recalcData_actedit(TransInfo *t)
|
||||
/* initialize relevant anim-context 'context' data from TransInfo data */
|
||||
/* NOTE: sync this with the code in ANIM_animdata_get_context() */
|
||||
ac.scene = t->scene;
|
||||
ac.scene_layer = t->sl;
|
||||
ac.obact = OBACT_NEW;
|
||||
ac.sa = t->sa;
|
||||
ac.ar = t->ar;
|
||||
|
||||
Reference in New Issue
Block a user