mirror of https://github.com/procxx/kepka.git
Don't show receivedTill for local loaders.
This commit is contained in:
parent
67b9fe846b
commit
8399f4189f
|
@ -161,6 +161,9 @@ void Player::trackSendReceivedTill(
|
||||||
Expects(state.duration != kTimeUnknown);
|
Expects(state.duration != kTimeUnknown);
|
||||||
Expects(state.receivedTill != kTimeUnknown);
|
Expects(state.receivedTill != kTimeUnknown);
|
||||||
|
|
||||||
|
if (!_remoteLoader) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
const auto receivedTill = std::max(
|
const auto receivedTill = std::max(
|
||||||
state.receivedTill,
|
state.receivedTill,
|
||||||
_previousReceivedTill);
|
_previousReceivedTill);
|
||||||
|
@ -668,7 +671,7 @@ Media::Player::TrackState Player::prepareLegacyState() const {
|
||||||
} else if (_options.loop && _totalDuration > 0) {
|
} else if (_options.loop && _totalDuration > 0) {
|
||||||
result.position %= _totalDuration;
|
result.position %= _totalDuration;
|
||||||
}
|
}
|
||||||
result.receivedTill = getCurrentReceivedTill();
|
result.receivedTill = _remoteLoader ? getCurrentReceivedTill() : 0;
|
||||||
result.length = _totalDuration;
|
result.length = _totalDuration;
|
||||||
if (result.length == kTimeUnknown) {
|
if (result.length == kTimeUnknown) {
|
||||||
const auto document = _options.audioId.audio();
|
const auto document = _options.audioId.audio();
|
||||||
|
|
Loading…
Reference in New Issue