mirror of https://gitlab.com/pamhyr/pamhyr2
geometry: Make parent as optional.
parent
3617fde986
commit
0546b304be
|
|
@ -16,7 +16,7 @@ from Model.Geometry.ProfileXYZ import ProfileXYZ
|
||||||
from Model.Except import FileFormatError, exception_message_box
|
from Model.Except import FileFormatError, exception_message_box
|
||||||
|
|
||||||
class Reach:
|
class Reach:
|
||||||
def __init__(self, parent):
|
def __init__(self, parent=None):
|
||||||
self._parent = parent
|
self._parent = parent
|
||||||
self._profiles: List[Profile] = []
|
self._profiles: List[Profile] = []
|
||||||
|
|
||||||
|
|
@ -39,6 +39,9 @@ class Reach:
|
||||||
|
|
||||||
@property
|
@property
|
||||||
def name(self):
|
def name(self):
|
||||||
|
if self._parent == None:
|
||||||
|
return ""
|
||||||
|
|
||||||
return self._parent.name
|
return self._parent.name
|
||||||
|
|
||||||
@property
|
@property
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue