Changeset View
Changeset View
Standalone View
Standalone View
source/blender/makesrna/intern/rna_armature.c
| Show First 20 Lines • Show All 415 Lines • ▼ Show 20 Lines | static void rna_EditBone_connected_check(EditBone *ebone) | ||||
| } | } | ||||
| } | } | ||||
| static void rna_EditBone_connected_set(PointerRNA *ptr, bool value) | static void rna_EditBone_connected_set(PointerRNA *ptr, bool value) | ||||
| { | { | ||||
| EditBone *ebone = (EditBone *)(ptr->data); | EditBone *ebone = (EditBone *)(ptr->data); | ||||
| if (value) { | if (value) { | ||||
| /* Don't allow enabling use_connected when there is no parent. */ | |||||
| if (ebone->parent != NULL) { | |||||
| ebone->flag |= BONE_CONNECTED; | ebone->flag |= BONE_CONNECTED; | ||||
| } | } | ||||
| } | |||||
| else { | else { | ||||
| ebone->flag &= ~BONE_CONNECTED; | ebone->flag &= ~BONE_CONNECTED; | ||||
| } | } | ||||
| rna_EditBone_connected_check(ebone); | rna_EditBone_connected_check(ebone); | ||||
| } | } | ||||
| static PointerRNA rna_EditBone_parent_get(PointerRNA *ptr) | static PointerRNA rna_EditBone_parent_get(PointerRNA *ptr) | ||||
| ▲ Show 20 Lines • Show All 1,106 Lines • Show Last 20 Lines | |||||