Bug 1378631. P2 - remove AbstractMediaDecoder::CanonicalDurationOrNull().
MozReview-Commit-ID: 9zWPcYZndsQ
--- a/dom/media/AbstractMediaDecoder.h
+++ b/dom/media/AbstractMediaDecoder.h
@@ -41,21 +41,16 @@ typedef nsDataHashtable<nsCStringHashKey
class AbstractMediaDecoder : public nsIObserver
{
public:
// Increments the parsed, decoded and dropped frame counters by the passed in
// counts.
// Can be called on any thread.
virtual void NotifyDecodedFrames(const FrameStatisticsData& aStats) = 0;
- virtual AbstractCanonical<media::NullableTimeUnit>* CanonicalDurationOrNull()
- {
- return nullptr;
- };
-
// Returns an event that will be notified when the owning document changes state
// and we might have a new compositor. If this new compositor requires us to
// recreate our decoders, then we expect the existing decoderis to return an
// error independently of this.
virtual MediaEventSource<RefPtr<layers::KnowsCompositor>>*
CompositorUpdatedEvent()
{
return nullptr;
--- a/dom/media/MediaDecoder.cpp
+++ b/dom/media/MediaDecoder.cpp
@@ -192,23 +192,16 @@ MediaDecoder::RemoveOutputStream(MediaSt
double
MediaDecoder::GetDuration()
{
MOZ_ASSERT(NS_IsMainThread());
return mDuration;
}
-AbstractCanonical<media::NullableTimeUnit>*
-MediaDecoder::CanonicalDurationOrNull()
-{
- MOZ_ASSERT(mDecoderStateMachine);
- return mDecoderStateMachine->CanonicalDuration();
-}
-
void
MediaDecoder::SetInfinite(bool aInfinite)
{
MOZ_ASSERT(NS_IsMainThread());
MOZ_DIAGNOSTIC_ASSERT(!IsShutdown());
mInfiniteStream = aInfinite;
DurationChanged();
}
--- a/dom/media/MediaDecoder.h
+++ b/dom/media/MediaDecoder.h
@@ -775,17 +775,16 @@ protected:
// Current decoding position in the stream. This is where the decoder
// is up to consuming the stream. This is not adjusted during decoder
// seek operations, but it's updated at the end when we start playing
// back again.
Canonical<int64_t> mDecoderPosition;
public:
- AbstractCanonical<media::NullableTimeUnit>* CanonicalDurationOrNull() override;
AbstractCanonical<double>* CanonicalVolume() { return &mVolume; }
AbstractCanonical<bool>* CanonicalPreservesPitch()
{
return &mPreservesPitch;
}
AbstractCanonical<bool>* CanonicalLooping()
{
return &mLooping;