diff options
Diffstat (limited to 'abcontroller.py')
-rw-r--r-- | abcontroller.py | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/abcontroller.py b/abcontroller.py index 0a10078..c04b8db 100644 --- a/abcontroller.py +++ b/abcontroller.py @@ -42,16 +42,17 @@ class ABController: self._currentLimits = _AB(aLimit, bLimit) def positionChanged(self, position): - if not self._currentLimits: - return if position > self._currentLimits.b and self._setPositionCallback and self._enabled: self._setPositionCallback(self._currentLimits.a) def setEnable(self, enable): self._enabled = enable - def getLimits(self, song): + def getStoredLimits(self, song): return self._limits.get(song) + def getCurrentLimits(self): + return self._currentLimits + def clear(self): self.__init__(enabled=self._enabled, callback=self._setPositionCallback) |