update components

This commit is contained in:
Luke Pulverenti 2016-05-03 13:58:24 -04:00
parent 3ab597cb01
commit c2d70081cf
15 changed files with 198 additions and 204 deletions

View file

@ -55,6 +55,12 @@ class BufferHelper {
buffered2.push(buffered[i]);
}
}
// in case current position is located before buffered time ranges, report area as not buffered
if (buffered2.length && pos < buffered2[0].start) {
return {len: 0, start: pos, end: pos, nextStart : buffered2[0].start};
}
for (i = 0, bufferLen = 0, bufferStart = bufferEnd = pos; i < buffered2.length; i++) {
var start = buffered2[i].start,
end = buffered2[i].end;