mirror of
https://github.com/onyx-and-iris/vban-cmd-python.git
synced 2025-01-18 18:40:47 +00:00
isdirty now aliases is_updated in strip/bus level classes
This commit is contained in:
parent
6971feb398
commit
d12f988c7d
@ -3,7 +3,6 @@ from abc import abstractmethod
|
|||||||
from enum import IntEnum
|
from enum import IntEnum
|
||||||
from typing import Union
|
from typing import Union
|
||||||
|
|
||||||
from .error import VMCMDErrors
|
|
||||||
from .iremote import IRemote
|
from .iremote import IRemote
|
||||||
from .meta import bus_mode_prop, channel_bool_prop, channel_label_prop
|
from .meta import bus_mode_prop, channel_bool_prop, channel_label_prop
|
||||||
|
|
||||||
@ -94,9 +93,16 @@ class BusLevel(IRemote):
|
|||||||
return self.getter()
|
return self.getter()
|
||||||
|
|
||||||
@property
|
@property
|
||||||
def is_updated(self) -> bool:
|
def isdirty(self) -> bool:
|
||||||
|
"""
|
||||||
|
Returns dirty status for this specific channel.
|
||||||
|
|
||||||
|
Expected to be used in a callback only.
|
||||||
|
"""
|
||||||
return any(self._remote._bus_comp[self.range[0] : self.range[-1]])
|
return any(self._remote._bus_comp[self.range[0] : self.range[-1]])
|
||||||
|
|
||||||
|
is_updated = isdirty
|
||||||
|
|
||||||
|
|
||||||
def _make_bus_mode_mixin():
|
def _make_bus_mode_mixin():
|
||||||
"""Creates a mixin of Bus Modes."""
|
"""Creates a mixin of Bus Modes."""
|
||||||
|
@ -125,9 +125,16 @@ class StripLevel(IRemote):
|
|||||||
return
|
return
|
||||||
|
|
||||||
@property
|
@property
|
||||||
def is_updated(self) -> bool:
|
def isdirty(self) -> bool:
|
||||||
|
"""
|
||||||
|
Returns dirty status for this specific channel.
|
||||||
|
|
||||||
|
Expected to be used in a callback only.
|
||||||
|
"""
|
||||||
return any(self._remote._strip_comp[self.range[0] : self.range[-1]])
|
return any(self._remote._strip_comp[self.range[0] : self.range[-1]])
|
||||||
|
|
||||||
|
is_updated = isdirty
|
||||||
|
|
||||||
|
|
||||||
class GainLayer(IRemote):
|
class GainLayer(IRemote):
|
||||||
def __init__(self, remote, index, i):
|
def __init__(self, remote, index, i):
|
||||||
|
Loading…
Reference in New Issue
Block a user