diff --git a/syncplay/__init__.py b/syncplay/__init__.py index d1a337626..132569213 100644 --- a/syncplay/__init__.py +++ b/syncplay/__init__.py @@ -1,4 +1,4 @@ version = '1.4.0' milestone = 'Yoitsu' -release_number = '35' +release_number = '36' projectURL = 'http://syncplay.pl/' diff --git a/syncplay/players/vlc.py b/syncplay/players/vlc.py index 59c95100e..b491c39a6 100644 --- a/syncplay/players/vlc.py +++ b/syncplay/players/vlc.py @@ -215,9 +215,14 @@ def lineReceived(self, line): self._client.ui.showDebugMessage("Treating 'playing' response as 'paused' due to VLC EOF bug") self._pausedAsk.set() elif name == "position": + newPosition = float(value.replace(",", ".")) if (value != "no-input" and self._filechanged == False) else self._client.getGlobalPosition() + if newPosition == self._previousPosition and newPosition <> self._duration and not self._paused: + self._client.ui.showDebugMessage("Not considering position {} duplicate as new time because of VLC time precision bug".format(newPosition)) + self._positionAsk.set() + return self._previousPreviousPosition = self._previousPosition self._previousPosition = self._position - self._position = float(value.replace(",", ".")) if (value != "no-input" and self._filechanged == False) else self._client.getGlobalPosition() + self._position = newPosition if self._position < 0 and self._duration > 2147 and self._vlcVersion == "3.0.0": self.drop(getMessage("vlc-failed-versioncheck")) self._lastVLCPositionUpdate = time.time()