зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1297880: Have GetSeekable return an empty range if duration is not r=jwwang
yet known. r?jwwang MozReview-Commit-ID: 4e1k42FlW1z --HG-- extra : rebase_source : 47c94026157a278192f2388a4d92768d5454c384
This commit is contained in:
Родитель
5cf46e081c
Коммит
745006a3fc
|
@ -1425,6 +1425,12 @@ media::TimeIntervals
|
|||
MediaDecoder::GetSeekable()
|
||||
{
|
||||
MOZ_ASSERT(NS_IsMainThread());
|
||||
|
||||
if (IsNaN(GetDuration())) {
|
||||
// We do not have a duration yet, we can't determine the seekable range.
|
||||
return TimeIntervals();
|
||||
}
|
||||
|
||||
// We can seek in buffered range if the media is seekable. Also, we can seek
|
||||
// in unbuffered ranges if the transport level is seekable (local file or the
|
||||
// server supports range requests, etc.) or in cue-less WebMs
|
||||
|
|
Загрузка…
Ссылка в новой задаче