svn merge -r 20373:20515 https://svn.blender.org/svnroot/bf-blender/branches/blender2...
[blender.git] / release / ui / buttons_data_empty.py
1
2 import bpy
3
4 class DataButtonsPanel(bpy.types.Panel):
5         __space_type__ = "BUTTONS_WINDOW"
6         __region_type__ = "WINDOW"
7         __context__ = "data"
8         
9         def poll(self, context):
10                 ob = context.active_object
11                 return (ob and ob.type == 'EMPTY')
12         
13 class DATA_PT_empty(DataButtonsPanel):
14         __idname__ = "DATA_PT_empty"
15         __label__ = "Empty"
16
17         def draw(self, context):
18                 ob = context.active_object
19                 layout = self.layout
20
21                 layout.itemR(ob, "empty_draw_type")
22                 layout.itemR(ob, "empty_draw_size")
23                 
24 bpy.types.register(DATA_PT_empty)