blender/release/ui/buttons_data_empty.py
Brecht Van Lommel dc7d0ef474 UI:
* Add Lamp Fallof Curve and Texture Color Ramp panels.
* Use button space context data.
* A few other minor python layout script updates.
2009-06-03 00:17:35 +00:00

25 lines
504 B
Python

import bpy
class DataButtonsPanel(bpy.types.Panel):
__space_type__ = "BUTTONS_WINDOW"
__region_type__ = "WINDOW"
__context__ = "data"
def poll(self, context):
ob = context.object
return (ob and ob.type == 'EMPTY')
class DATA_PT_empty(DataButtonsPanel):
__idname__ = "DATA_PT_empty"
__label__ = "Empty"
def draw(self, context):
ob = context.object
layout = self.layout
layout.itemR(ob, "empty_draw_type")
layout.itemR(ob, "empty_draw_size")
bpy.types.register(DATA_PT_empty)