2.5 - A few bugfixes...
authorJoshua Leung <aligorith@gmail.com>
Thu, 3 Sep 2009 12:20:59 +0000 (12:20 +0000)
committerJoshua Leung <aligorith@gmail.com>
Thu, 3 Sep 2009 12:20:59 +0000 (12:20 +0000)
* Autoside renaming tools in EditMode for armatures now works again. (Wrong property name)
* Action used by NLA Strips can now be chosen/changed to another action

release/ui/buttons_data_bone.py
release/ui/space_view3d.py
source/blender/editors/armature/editarmature.c
source/blender/editors/space_nla/nla_buttons.c
source/blender/makesrna/intern/rna_nla.c

index 8098648886b4fc5420feb5624f58385b42b0033c..276ca066af5e816d464e8165aad6055817d7e7cb 100644 (file)
@@ -80,6 +80,7 @@ class BONE_PT_bone(BoneButtonsPanel):
                
                if not bone:
                        bone = context.edit_bone
+                       pchan = None
                else:
                        pchan = ob.pose.pose_channels[context.bone.name]
 
index 8477e52acab518af247f6438fe903bb7e9f93263..1d7ea280222f90426e3e97154d0dad6a8d5f8570 100644 (file)
@@ -1069,9 +1069,9 @@ class VIEW3D_MT_edit_ARMATURE(bpy.types.Menu):
                
                layout.itemS()
 
-               layout.item_enumO("armature.autoside_names", "axis", 'XAXIS', text="AutoName Left/Right")
-               layout.item_enumO("armature.autoside_names", "axis", 'YAXIS', text="AutoName Front/Back")
-               layout.item_enumO("armature.autoside_names", "axis", 'ZAXIS', text="AutoName Top/Bottom")
+               layout.item_enumO("armature.autoside_names", "type", 'XAXIS', text="AutoName Left/Right")
+               layout.item_enumO("armature.autoside_names", "type", 'YAXIS', text="AutoName Front/Back")
+               layout.item_enumO("armature.autoside_names", "type", 'ZAXIS', text="AutoName Top/Bottom")
                layout.itemO("armature.flip_names")
 
                layout.itemS()
index 632f037679f49f48e1ae1a5f2fce437523617cc4..9f83733a64060a496959b70e7d72b4ee9a270494 100644 (file)
@@ -5387,7 +5387,7 @@ static int armature_autoside_names_exec (bContext *C, wmOperator *op)
        Object *ob= CTX_data_edit_object(C);
        bArmature *arm;
        char newname[32];
-       short axis= RNA_enum_get(op->ptr, "axis");
+       short axis= RNA_enum_get(op->ptr, "type");
        
        /* paranoia checks */
        if (ELEM(NULL, ob, ob->pose)) 
@@ -5434,7 +5434,7 @@ void ARMATURE_OT_autoside_names (wmOperatorType *ot)
        ot->flag= OPTYPE_REGISTER|OPTYPE_UNDO;
        
        /* settings */
-       RNA_def_enum(ot->srna, "axis", axis_items, 0, "Axis", "Axis tag names with.");
+       RNA_def_enum(ot->srna, "type", axis_items, 0, "Axis", "Axis tag names with.");
 }
 
 
index 2ffca5185f23d0d82c20b2007a2cd4879e96afae..facea34510e6952a15ac038ebdcf4955c73e0701 100644 (file)
@@ -119,6 +119,7 @@ static int nla_panel_context(const bContext *C, PointerRNA *adt_ptr, PointerRNA
        ANIM_animdata_filter(&ac, &anim_data, filter, ac.data, ac.datatype);
        
        for (ale= anim_data.first; ale; ale= ale->next) {
+               // TODO: need some way to select active animdata too...
                if (ale->type == ANIMTYPE_NLATRACK) {
                        NlaTrack *nlt= (NlaTrack *)ale->data;
                        AnimData *adt= ale->adt;
@@ -210,7 +211,7 @@ static void nla_panel_animdata (const bContext *C, Panel *pa)
        /* Active Action Properties ------------------------------------- */
        /* action */
        row= uiLayoutRow(layout, 1);
-               uiItemR(row, NULL, 0, &adt_ptr, "action", 0);
+               uiTemplateID(row, C, &adt_ptr, "action", NULL, NULL/*"ACT_OT_new", "ACT_OT_unlink"*/); // XXX: need to make these operators
        
        /* extrapolation */
        row= uiLayoutRow(layout, 1);
index 98fdf4a68787f031838ccef42836daf0422731be..690a198f12cb19fd767d28388b46a970637236dd 100644 (file)
@@ -350,6 +350,7 @@ void rna_def_nlastrip(BlenderRNA *brna)
        /* Action */
        prop= RNA_def_property(srna, "action", PROP_POINTER, PROP_NONE);
        RNA_def_property_pointer_sdna(prop, NULL, "act");
+       RNA_def_property_flag(prop, PROP_EDITABLE); 
        RNA_def_property_ui_text(prop, "Action", "Action referenced by this strip.");
        
        /* Action extents */