Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBrecht Van Lommel <brechtvanlommel@pandora.be>2009-06-07 17:36:12 +0400
committerBrecht Van Lommel <brechtvanlommel@pandora.be>2009-06-07 17:36:12 +0400
commiteecf7722b635545f0f5c51b74a15418e3cc9f47e (patch)
tree9d74c4603411f4aa6d527d229d2ea05220f81aec /release/ui/buttons_data_armature.py
parent0a9dea9d7d2db373b47395d4b5d564e559da5229 (diff)
UI Buttons:
* Context now allows pinning a datablock, independent of selection. * Initial ID browse buttons for most buttons tabs. * Browsing from world to texture now displays world textures again, but is a bit of a hack, not sure there is a right way to do this. * There's a button to switch between active materials and textures now, only temporary though. * There's some code to put context part in own region, disabled still because it doesn't work that well yet.
Diffstat (limited to 'release/ui/buttons_data_armature.py')
-rw-r--r--release/ui/buttons_data_armature.py49
1 files changed, 31 insertions, 18 deletions
diff --git a/release/ui/buttons_data_armature.py b/release/ui/buttons_data_armature.py
index 46a077ebfdb..fd317baf861 100644
--- a/release/ui/buttons_data_armature.py
+++ b/release/ui/buttons_data_armature.py
@@ -14,27 +14,40 @@ class DATA_PT_skeleton(DataButtonsPanel):
__label__ = "Skeleton"
def draw(self, context):
+ ob = context.object
arm = context.armature
+ space = context.space_data
layout = self.layout
-
- layout.itemR(arm, "rest_position")
-
- split = layout.split()
- sub = split.column()
- sub.itemL(text="Deform:")
- sub.itemR(arm, "deform_vertexgroups", text="Vertes Groups")
- sub.itemR(arm, "deform_envelope", text="Envelopes")
- sub.itemR(arm, "deform_quaternion", text="Quaternion")
- sub.itemR(arm, "deform_bbone_rest", text="B-Bones Rest")
- #sub.itemR(arm, "x_axis_mirror")
- #sub.itemR(arm, "auto_ik")
-
- sub = split.column()
- sub.itemL(text="Layers:")
- sub.itemL(text="LAYERS")
- #sub.itemR(arm, "layer")
- #sub.itemR(arm, "layer_protection")
+ split = layout.split(percentage=0.65)
+
+ if ob:
+ split.template_ID(context, ob, "data")
+ split.itemS()
+ elif arm:
+ split.template_ID(context, space, "pin_id")
+ split.itemS()
+
+ if arm:
+ layout.itemS()
+ layout.itemR(arm, "rest_position")
+
+ split = layout.split()
+
+ sub = split.column()
+ sub.itemL(text="Deform:")
+ sub.itemR(arm, "deform_vertexgroups", text="Vertes Groups")
+ sub.itemR(arm, "deform_envelope", text="Envelopes")
+ sub.itemR(arm, "deform_quaternion", text="Quaternion")
+ sub.itemR(arm, "deform_bbone_rest", text="B-Bones Rest")
+ #sub.itemR(arm, "x_axis_mirror")
+ #sub.itemR(arm, "auto_ik")
+
+ sub = split.column()
+ sub.itemL(text="Layers:")
+ sub.itemL(text="LAYERS")
+ #sub.itemR(arm, "layer")
+ #sub.itemR(arm, "layer_protection")
class DATA_PT_display(DataButtonsPanel):
__idname__ = "DATA_PT_display"