mirror of
https://git.code.sf.net/p/quake/quakeforge
synced 2024-11-26 14:20:59 +00:00
Use icons to distinquish brush ents from others.
Mesh-data icons indicate brush entities, object-data icons indicate the others.
This commit is contained in:
parent
06fd951a55
commit
fde8d29899
1 changed files with 7 additions and 1 deletions
|
@ -59,7 +59,13 @@ def ecm_draw(self, context):
|
|||
layout = self.layout
|
||||
for item in self.menu_items:
|
||||
if type(item[1]) is str:
|
||||
layout.operator("object.add_entity", text=item[0]).entclass=item[1]
|
||||
ec = context.scene.qfmap.entity_classes.entity_classes[item[1]]
|
||||
if ec.size:
|
||||
icon = 'OBJECT_DATA'
|
||||
else:
|
||||
icon = 'MESH_DATA'
|
||||
op = layout.operator("object.add_entity", text=item[0], icon=icon)
|
||||
op.entclass=item[1]
|
||||
else:
|
||||
layout.menu(item[1].bl_idname)
|
||||
|
||||
|
|
Loading…
Reference in a new issue