Welcome to mirror list, hosted at ThFree Co, Russian Federation.

GCodeListDecorator.py « Scene « cura - github.com/Ultimaker/Cura.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: b8db706db34c9419839f6fd3d03bde67476480c4 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
from UM.Scene.SceneNodeDecorator import SceneNodeDecorator
from typing import List, Optional


class GCodeListDecorator(SceneNodeDecorator):
    def __init__(self) -> None:
        super().__init__()
        self._gcode_list = []  # type: List[str]
        self._filename = None  # type: Optional[str]

    def getGcodeFileName(self) -> Optional[str]:
        return self._filename

    def setGcodeFileName(self, filename: str) -> None:
        self._filename = filename

    def getGCodeList(self) -> List[str]:
        return self._gcode_list

    def setGCodeList(self, gcode_list: List[str]) -> None:
        self._gcode_list = gcode_list

    def __deepcopy__(self, memo) -> "GCodeListDecorator":
        copied_decorator = GCodeListDecorator()
        copied_decorator.setGCodeList(self.getGCodeList())
        return copied_decorator