mirror of
https://github.com/IfcOpenShell/IfcOpenShell.git
synced 2026-09-22 22:32:28 +00:00
avoid errors unregistering tools from tests
This commit is contained in:
@@ -60,6 +60,7 @@ def register():
|
|||||||
|
|
||||||
|
|
||||||
def unregister():
|
def unregister():
|
||||||
|
if not bpy.app.background:
|
||||||
bpy.utils.unregister_tool(workspace.SpatialTool)
|
bpy.utils.unregister_tool(workspace.SpatialTool)
|
||||||
del bpy.types.Scene.BIMSpatialProperties
|
del bpy.types.Scene.BIMSpatialProperties
|
||||||
del bpy.types.Object.BIMObjectSpatialProperties
|
del bpy.types.Object.BIMObjectSpatialProperties
|
||||||
|
|||||||
@@ -100,6 +100,7 @@ def register():
|
|||||||
|
|
||||||
|
|
||||||
def unregister():
|
def unregister():
|
||||||
|
if not bpy.app.background:
|
||||||
bpy.utils.unregister_tool(workspace.StructuralTool)
|
bpy.utils.unregister_tool(workspace.StructuralTool)
|
||||||
del bpy.types.Scene.BIMStructuralProperties
|
del bpy.types.Scene.BIMStructuralProperties
|
||||||
del bpy.types.Object.BIMStructuralProperties
|
del bpy.types.Object.BIMStructuralProperties
|
||||||
|
|||||||
Reference in New Issue
Block a user