Bug 1112424 Part 3 - Adds size of the resource to the output a=ajones

--HG--
extra : rebase_source : cf54f1263324dd498f9fd7beb7ea5ebe574a83d6
This commit is contained in:
Chris Double 2015-01-29 15:36:02 +13:00
Родитель 023c0e49cd
Коммит b7c69754d3
1 изменённых файлов: 6 добавлений и 4 удалений

Просмотреть файл

@ -982,9 +982,10 @@ MediaSourceReader::GetMozDebugReaderData(nsAString& aString)
nsRefPtr<dom::TimeRanges> ranges = new dom::TimeRanges(); nsRefPtr<dom::TimeRanges> ranges = new dom::TimeRanges();
mAudioTrack->Decoders()[i]->GetBuffered(ranges); mAudioTrack->Decoders()[i]->GetBuffered(ranges);
result += nsPrintfCString("\t\tReader %d: %p ranges=%s active=%s\n", result += nsPrintfCString("\t\tReader %d: %p ranges=%s active=%s size=%lld\n",
i, newReader.get(), DumpTimeRanges(ranges).get(), i, newReader.get(), DumpTimeRanges(ranges).get(),
newReader.get() == mAudioReader.get() ? "true" : "false"); newReader.get() == mAudioReader.get() ? "true" : "false",
mAudioTrack->Decoders()[i]->GetResource()->GetSize());
} }
} }
@ -995,9 +996,10 @@ MediaSourceReader::GetMozDebugReaderData(nsAString& aString)
nsRefPtr<dom::TimeRanges> ranges = new dom::TimeRanges(); nsRefPtr<dom::TimeRanges> ranges = new dom::TimeRanges();
mVideoTrack->Decoders()[i]->GetBuffered(ranges); mVideoTrack->Decoders()[i]->GetBuffered(ranges);
result += nsPrintfCString("\t\tReader %d: %p ranges=%s active=%s\n", result += nsPrintfCString("\t\tReader %d: %p ranges=%s active=%s size=%lld\n",
i, newReader.get(), DumpTimeRanges(ranges).get(), i, newReader.get(), DumpTimeRanges(ranges).get(),
newReader.get() == mVideoReader.get() ? "true" : "false"); newReader.get() == mVideoReader.get() ? "true" : "false",
mVideoTrack->Decoders()[i]->GetResource()->GetSize());
} }
} }
aString += NS_ConvertUTF8toUTF16(result); aString += NS_ConvertUTF8toUTF16(result);