Merge with 2.5 -r 21619:21756.
[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                 return (context.object.type == 'EMPTY')
11         
12 class DATA_PT_empty(DataButtonsPanel):
13         __idname__ = "DATA_PT_empty"
14         __label__ = "Empty"
15
16         def draw(self, context):
17                 layout = self.layout
18                 ob = context.object
19
20                 layout.itemR(ob, "empty_draw_type")
21                 layout.itemR(ob, "empty_draw_size")
22                 
23 bpy.types.register(DATA_PT_empty)