From 0656dd53c3651bb9634b301058bc2ec177b07c6a Mon Sep 17 00:00:00 2001 From: Arjen Hiemstra Date: Mon, 20 Mar 2017 17:28:42 +0100 Subject: [PATCH] Override setNextStack in GlobalStack and raise an error if called Since the global stack should never have a next stack Contributes to CURA-3497 --- cura/Settings/GlobalStack.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/cura/Settings/GlobalStack.py b/cura/Settings/GlobalStack.py index a2a7ae59dd..5013d1505e 100644 --- a/cura/Settings/GlobalStack.py +++ b/cura/Settings/GlobalStack.py @@ -12,6 +12,9 @@ class GlobalStack(ContainerStack): def __init__(self, container_id, *args, **kwargs): super().__init__(container_id, *args, **kwargs) + def setNextStack(self, next_stack): + raise CannotSetNextStackError("Global stack cannot have a next stack!") + global_stack_mime = MimeType( name = "application/x-cura-globalstack", comment = "Cura Global Stack",