mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 799344 - Remove virtual from media state machine methods, since they're not inherited. r=roc
This commit is contained in:
parent
a0956a77b0
commit
37519cec2a
@ -116,7 +116,7 @@ public:
|
||||
~nsBuiltinDecoderStateMachine();
|
||||
|
||||
// nsDecoderStateMachine interface
|
||||
virtual nsresult Init(nsBuiltinDecoderStateMachine* aCloneDonor);
|
||||
nsresult Init(nsBuiltinDecoderStateMachine* aCloneDonor);
|
||||
|
||||
// Enumeration for the valid decoding states
|
||||
enum State {
|
||||
@ -135,20 +135,20 @@ public:
|
||||
|
||||
// Set the audio volume. The decoder monitor must be obtained before
|
||||
// calling this.
|
||||
virtual void SetVolume(double aVolume);
|
||||
virtual void SetAudioCaptured(bool aCapture);
|
||||
virtual void Shutdown();
|
||||
void SetVolume(double aVolume);
|
||||
void SetAudioCaptured(bool aCapture);
|
||||
void Shutdown();
|
||||
|
||||
// Called from the main thread to get the duration. The decoder monitor
|
||||
// must be obtained before calling this. It is in units of microseconds.
|
||||
virtual int64_t GetDuration();
|
||||
int64_t GetDuration();
|
||||
|
||||
// Called from the main thread to set the duration of the media resource
|
||||
// if it is able to be obtained via HTTP headers. Called from the
|
||||
// state machine thread to set the duration if it is obtained from the
|
||||
// media metadata. The decoder monitor must be obtained before calling this.
|
||||
// aDuration is in microseconds.
|
||||
virtual void SetDuration(int64_t aDuration);
|
||||
void SetDuration(int64_t aDuration);
|
||||
|
||||
// Called while decoding metadata to set the end time of the media
|
||||
// resource. The decoder monitor must be obtained before calling this.
|
||||
@ -157,7 +157,7 @@ public:
|
||||
|
||||
// Functions used by assertions to ensure we're calling things
|
||||
// on the appropriate threads.
|
||||
virtual bool OnDecodeThread() const {
|
||||
bool OnDecodeThread() const {
|
||||
return IsCurrentThread(mDecodeThread);
|
||||
}
|
||||
bool OnStateMachineThread() const;
|
||||
@ -165,43 +165,43 @@ public:
|
||||
return IsCurrentThread(mAudioThread);
|
||||
}
|
||||
|
||||
virtual nsHTMLMediaElement::NextFrameStatus GetNextFrameStatus();
|
||||
nsHTMLMediaElement::NextFrameStatus GetNextFrameStatus();
|
||||
|
||||
// Cause state transitions. These methods obtain the decoder monitor
|
||||
// to synchronise the change of state, and to notify other threads
|
||||
// that the state has changed.
|
||||
virtual void Play();
|
||||
void Play();
|
||||
|
||||
// Seeks to aTime in seconds.
|
||||
virtual void Seek(double aTime);
|
||||
void Seek(double aTime);
|
||||
|
||||
// Returns the current playback position in seconds.
|
||||
// Called from the main thread to get the current frame time. The decoder
|
||||
// monitor must be obtained before calling this.
|
||||
virtual double GetCurrentTime() const;
|
||||
double GetCurrentTime() const;
|
||||
|
||||
// Clear the flag indicating that a playback position change event
|
||||
// is currently queued. This is called from the main thread and must
|
||||
// be called with the decode monitor held.
|
||||
virtual void ClearPositionChangeFlag();
|
||||
void ClearPositionChangeFlag();
|
||||
|
||||
// Called from the main thread to set whether the media resource can
|
||||
// seek into unbuffered ranges. The decoder monitor must be obtained
|
||||
// before calling this.
|
||||
virtual void SetSeekable(bool aSeekable);
|
||||
void SetSeekable(bool aSeekable);
|
||||
|
||||
// Update the playback position. This can result in a timeupdate event
|
||||
// and an invalidate of the frame being dispatched asynchronously if
|
||||
// there is no such event currently queued.
|
||||
// Only called on the decoder thread. Must be called with
|
||||
// the decode monitor held.
|
||||
virtual void UpdatePlaybackPosition(int64_t aTime);
|
||||
void UpdatePlaybackPosition(int64_t aTime);
|
||||
|
||||
// Causes the state machine to switch to buffering state, and to
|
||||
// immediately stop playback and buffer downloaded data. Must be called
|
||||
// with the decode monitor held. Called on the state machine thread and
|
||||
// the main thread.
|
||||
virtual void StartBuffering();
|
||||
void StartBuffering();
|
||||
|
||||
// State machine thread run function. Defers to RunStateMachine().
|
||||
NS_IMETHOD Run();
|
||||
@ -275,7 +275,7 @@ public:
|
||||
|
||||
// Sets the current frame buffer length for the MozAudioAvailable event.
|
||||
// Accessed on the main and state machine threads.
|
||||
virtual void SetFrameBufferLength(uint32_t aLength);
|
||||
void SetFrameBufferLength(uint32_t aLength);
|
||||
|
||||
// Returns the shared state machine thread.
|
||||
static nsIThread* GetStateMachineThread();
|
||||
@ -323,9 +323,9 @@ public:
|
||||
|
||||
// Returns true if the state machine has shutdown or is in the process of
|
||||
// shutting down. The decoder monitor must be held while calling this.
|
||||
bool IsShutdown() MOZ_OVERRIDE;
|
||||
bool IsShutdown();
|
||||
|
||||
protected:
|
||||
private:
|
||||
class WakeDecoderRunnable : public nsRunnable {
|
||||
public:
|
||||
WakeDecoderRunnable(nsBuiltinDecoderStateMachine* aSM)
|
||||
@ -421,7 +421,7 @@ protected:
|
||||
// Pushes the image down the rendering pipeline. Called on the shared state
|
||||
// machine thread. The decoder monitor must *not* be held when calling this.
|
||||
void RenderVideoFrame(VideoData* aData, TimeStamp aTarget);
|
||||
|
||||
|
||||
// If we have video, display a video frame if it's time for display has
|
||||
// arrived, otherwise sleep until it's time for the next frame. Update the
|
||||
// current frame time as appropriate, and trigger ready state update. The
|
||||
@ -651,7 +651,7 @@ protected:
|
||||
// The presentation end time of the last video frame which has been displayed
|
||||
// in microseconds. Accessed from the state machine thread.
|
||||
int64_t mVideoFrameEndTime;
|
||||
|
||||
|
||||
// Volume of playback. 0.0 = muted. 1.0 = full volume. Read/Written
|
||||
// from the state machine and main threads. Synchronised via decoder
|
||||
// monitor.
|
||||
@ -694,7 +694,7 @@ protected:
|
||||
// True if mDuration has a value obtained from an HTTP header, or from
|
||||
// the media index/metadata. Accessed on the state machine thread.
|
||||
bool mGotDurationFromMetaData;
|
||||
|
||||
|
||||
// False while decode thread should be running. Accessed state machine
|
||||
// and decode threads. Syncrhonised by decoder monitor.
|
||||
bool mStopDecodeThread;
|
||||
@ -749,8 +749,7 @@ protected:
|
||||
// True if we've requested a new decode thread, but it has not yet been
|
||||
// created. Synchronized by the decoder monitor.
|
||||
bool mRequestedNewDecodeThread;
|
||||
|
||||
private:
|
||||
|
||||
// Manager for queuing and dispatching MozAudioAvailable events. The
|
||||
// event manager is accessed from the state machine and audio threads,
|
||||
// and takes care of synchronizing access to its internal queue.
|
||||
|
Loading…
Reference in New Issue
Block a user