mirror of
https://github.com/Ultimaker/Cura.git
synced 2025-07-13 09:47:50 -06:00
Add missing typing to number of decorators
This commit is contained in:
parent
0ce9bf61be
commit
d83241f13a
4 changed files with 58 additions and 36 deletions
|
@ -1,18 +1,19 @@
|
|||
from UM.Scene.SceneNodeDecorator import SceneNodeDecorator
|
||||
|
||||
|
||||
## A decorator that stores the amount an object has been moved below the platform.
|
||||
class ZOffsetDecorator(SceneNodeDecorator):
|
||||
def __init__(self):
|
||||
def __init__(self) -> None:
|
||||
super().__init__()
|
||||
self._z_offset = 0
|
||||
self._z_offset = 0.
|
||||
|
||||
def setZOffset(self, offset):
|
||||
def setZOffset(self, offset: float) -> None:
|
||||
self._z_offset = offset
|
||||
|
||||
def getZOffset(self):
|
||||
def getZOffset(self) -> float:
|
||||
return self._z_offset
|
||||
|
||||
def __deepcopy__(self, memo):
|
||||
def __deepcopy__(self, memo) -> "ZOffsetDecorator":
|
||||
copied_decorator = ZOffsetDecorator()
|
||||
copied_decorator.setZOffset(self.getZOffset())
|
||||
return copied_decorator
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue