diff -crB ./blender/source/blender/python/api2_2x/Bone.c ./blender2/source/blender/python/api2_2x/Bone.c *** ./blender/source/blender/python/api2_2x/Bone.c Sat Aug 1 13:11:50 2009 --- ./blender2/source/blender/python/api2_2x/Bone.c Sat Aug 1 12:56:44 2009 *************** *** 1273,1278 **** --- 1273,1301 ---- return 0; } + //-------------------------Bone.activate() + static PyObject *Bone_activate(BPy_Bone *self) + + { + struct Bone *firstbone = self->bone; // unset all bone's active flag first + while(firstbone->prev ) + firstbone= firstbone->prev; + + while(firstbone->next) { + firstbone->flag &= ~BONE_ACTIVE; + firstbone= firstbone->next; + } + + self->bone->flag |= BONE_ACTIVE; // this makes the bones curves display in the IPO editor + + allqueue(0x4010, 0); // refresh windows + allqueue(0x4037, 0); + allqueue(0x4027, 0); + allqueue(0x4030, 0); + + Py_RETURN_TRUE; + + } //------------------TYPE_OBECT IMPLEMENTATION-------------------------- //------------------------tp_methods *************** *** 1284,1289 **** --- 1307,1314 ---- "() - True/False - Bone has 1 or more children"}, {"getAllChildren", (PyCFunction) Bone_getAllChildren, METH_NOARGS, "() - All the children for this bone - including children's children"}, + {"activate", (PyCFunction) Bone_activate, METH_NOARGS, + "Display curves in the IPO editor"}, {NULL, NULL, 0, NULL} }; //------------------------tp_getset