mirror of
https://github.com/IfcOpenShell/IfcOpenShell.git
synced 2026-08-17 10:59:17 +00:00
bim.override_mesh_separate - invoke menu if called without argument
Mimicking default mesh.separate behaviour. @Gorgious56 I don't know if you've seen this before, but you might be interested - I've found a way to figure if operator wasn't called without any arguments.
This commit is contained in:
@@ -80,6 +80,11 @@ class OverrideMeshSeparate(bpy.types.Operator, tool.Ifc.Operator):
|
||||
items=[(i.identifier, i.name, i.description) for i in blender_type_prop.enum_items],
|
||||
)
|
||||
|
||||
def invoke(self, context, event):
|
||||
if "type" not in self.properties:
|
||||
return bpy.ops.wm.call_menu(name="BIM_MT_hotkey_separate")
|
||||
return self.execute(context)
|
||||
|
||||
def _execute(self, context):
|
||||
obj = context.active_object
|
||||
assert obj
|
||||
|
||||
Reference in New Issue
Block a user