Revision: 21192
          
http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=rev&root=bf-blender&revision=21192
Author:   blendix
Date:     2009-06-27 16:07:17 +0200 (Sat, 27 Jun 2009)

Log Message:
-----------
UI: move bone constraints panel to bone tab again.

Modified Paths:
--------------
    branches/blender2.5/blender/release/ui/buttons_object_constraint.py

Modified: branches/blender2.5/blender/release/ui/buttons_object_constraint.py
===================================================================
--- branches/blender2.5/blender/release/ui/buttons_object_constraint.py 
2009-06-27 14:02:21 UTC (rev 21191)
+++ branches/blender2.5/blender/release/ui/buttons_object_constraint.py 
2009-06-27 14:07:17 UTC (rev 21192)
@@ -529,20 +529,20 @@
 class BONE_PT_constraints(ConstraintButtonsPanel):
        __idname__ = "BONE_PT_constraints"
        __label__ = "Bone Constraints"
-       __context__ = "constraint"
+       __context__ = "bone"
 
        def poll(self, context):
                ob = context.object
-               return (ob and ob.type == "ARMATURE")
+               return (ob and ob.type == "ARMATURE" and context.bone)
                
        def draw(self, context):
                ob = context.object
-               pchan = ob.pose.pose_channels[0] # XXX
+               pchan = ob.pose.pose_channels[context.bone.name]
                layout = self.layout
 
-               #row = layout.row()
-               #row.item_menu_enumO("BONE_OT_constraint_add", "type")
-               #row.itemL();
+               row = layout.row()
+               row.item_menu_enumO("OBJECT_OT_constraint_add", "type")
+               row.itemL();
 
                for con in pchan.constraints:
                        self.draw_constraint(con)


_______________________________________________
Bf-blender-cvs mailing list
[email protected]
http://lists.blender.org/mailman/listinfo/bf-blender-cvs

Reply via email to