mirror of
https://github.com/IfcOpenShell/IfcOpenShell.git
synced 2026-09-20 23:36:20 +00:00
bim.copy_railing_parameters - add poll message
This commit is contained in:
@@ -360,7 +360,10 @@ class CopyRailingParameters(bpy.types.Operator, tool.Ifc.Operator):
|
|||||||
|
|
||||||
@classmethod
|
@classmethod
|
||||||
def poll(cls, context):
|
def poll(cls, context):
|
||||||
return context.active_object and len(context.selected_objects) > 1
|
if not context.active_object or len(context.selected_objects) < 1:
|
||||||
|
cls.poll_message_set("At least 2 objects must be selected.")
|
||||||
|
return False
|
||||||
|
return True
|
||||||
|
|
||||||
def _execute(self, context):
|
def _execute(self, context):
|
||||||
source_obj = context.active_object
|
source_obj = context.active_object
|
||||||
|
|||||||
Reference in New Issue
Block a user