bim.create_drawing - poll message

This commit is contained in:
Andrej730
2024-08-29 13:37:02 +05:00
parent 486eb259ea
commit aff893e690
@@ -204,7 +204,12 @@ class CreateDrawing(bpy.types.Operator):
@classmethod
def poll(cls, context):
return bool(tool.Ifc.get() and tool.Drawing.is_drawing_active())
if not tool.Ifc.get():
return False
if not tool.Drawing.is_drawing_active():
cls.poll_message_set("No active drawing.")
return False
return True
def invoke(self, context, event):
# printing all drawings on shift+click