mirror of
https://github.com/ynput/ayon-core.git
synced 2025-12-25 05:14:40 +01:00
base object may have pos_x and pos_y
This commit is contained in:
parent
8899ce974f
commit
de2d156fc4
1 changed files with 4 additions and 2 deletions
|
|
@ -24,7 +24,7 @@ class BaseObj:
|
|||
"margin-top", "margin-bottom", "width", "height"
|
||||
]
|
||||
|
||||
def __init__(self, parent, style={}, name=None):
|
||||
def __init__(self, parent, style={}, name=None, pos_x=None, pos_y=None):
|
||||
if not self.obj_type:
|
||||
raise NotImplementedError(
|
||||
"Class don't have set object type <{}>".format(
|
||||
|
|
@ -50,7 +50,9 @@ class BaseObj:
|
|||
self.id = uuid4()
|
||||
self.name = name
|
||||
self.items = {}
|
||||
self.final_style = None
|
||||
|
||||
self._pos_x = pos_x or 0
|
||||
self._pos_y = pos_y or 0
|
||||
|
||||
@property
|
||||
def main_style(self):
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue