Changeset View
Changeset View
Standalone View
Standalone View
source/blender/editors/interface/interface_anim.c
| Show First 20 Lines • Show All 312 Lines • ▼ Show 20 Lines | if (IS_AUTOKEY_ON(scene)) { | ||||
| WM_event_add_notifier(C, NC_ANIMATION | ND_KEYFRAME | NA_EDITED, NULL); | WM_event_add_notifier(C, NC_ANIMATION | ND_KEYFRAME | NA_EDITED, NULL); | ||||
| } | } | ||||
| } | } | ||||
| else { | else { | ||||
| id = but->rnapoin.id.data; | id = but->rnapoin.id.data; | ||||
| /* TODO: this should probably respect the keyingset only option for anim */ | /* TODO: this should probably respect the keyingset only option for anim */ | ||||
| if (autokeyframe_cfra_can_key(scene, id)) { | if (autokeyframe_cfra_can_key(scene, id)) { | ||||
| Depsgraph *depsgraph = CTX_data_depsgraph(C); | |||||
| ReportList *reports = CTX_wm_reports(C); | ReportList *reports = CTX_wm_reports(C); | ||||
| ToolSettings *ts = scene->toolsettings; | ToolSettings *ts = scene->toolsettings; | ||||
| short flag = ANIM_get_keyframing_flags(scene, 1); | short flag = ANIM_get_keyframing_flags(scene, 1); | ||||
| fcu->flag &= ~FCURVE_SELECTED; | fcu->flag &= ~FCURVE_SELECTED; | ||||
| /* Note: We use but->rnaindex instead of fcu->array_index, | /* Note: We use but->rnaindex instead of fcu->array_index, | ||||
| * because a button may control all items of an array at once. | * because a button may control all items of an array at once. | ||||
| * E.g., color wheels (see T42567). */ | * E.g., color wheels (see T42567). */ | ||||
| BLI_assert((fcu->array_index == but->rnaindex) || (but->rnaindex == -1)); | BLI_assert((fcu->array_index == but->rnaindex) || (but->rnaindex == -1)); | ||||
| insert_keyframe(bmain, | insert_keyframe(bmain, | ||||
| depsgraph, | |||||
| reports, | reports, | ||||
| id, | id, | ||||
| action, | action, | ||||
| ((fcu->grp) ? (fcu->grp->name) : (NULL)), | ((fcu->grp) ? (fcu->grp->name) : (NULL)), | ||||
| fcu->rna_path, | fcu->rna_path, | ||||
| but->rnaindex, | but->rnaindex, | ||||
| cfra, | cfra, | ||||
| ts->keyframe_type, | ts->keyframe_type, | ||||
| ▲ Show 20 Lines • Show All 54 Lines • Show Last 20 Lines | |||||